Skip to content

Commit

Permalink
created test for deleting users. a copule of fixes.
Browse files Browse the repository at this point in the history
  • Loading branch information
hpoul committed Jan 28, 2024
1 parent fbef39d commit d048df0
Show file tree
Hide file tree
Showing 9 changed files with 552 additions and 282 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -726,6 +726,17 @@ class FileCloudTable extends TableBase with TableConstants {
values: {'userId': user.id},
),
);
await ret.track(
TABLE_ATTACHMENT,
() async => await db.query(
'DELETE FROM $TABLE_ATTACHMENT a '
'WHERE a.$columnUserId = @userId '
'AND NOT EXISTS ('
'SELECT 1 FROM $TABLE_ATTACHMENT_TOUCH at WHERE at.$_columnAttachmentId = a.$columnId'
')',
values: {'userId': user.id},
),
);
await ret.track(
TABLE_FILE_TOKEN,
() async => await db.query(
Expand Down
Loading

0 comments on commit d048df0

Please sign in to comment.