Page MenuHomePhabricator

[keyserver] Update `deleteThread` and `deleteInaccessibleThreads` to handle thread image avatars
ClosedPublic

Authored by atul on Apr 10 2023, 12:12 PM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Nov 19, 8:50 AM
Unknown Object (File)
Mon, Nov 18, 10:01 AM
Unknown Object (File)
Mon, Nov 18, 7:14 AM
Unknown Object (File)
Mon, Nov 18, 6:56 AM
Unknown Object (File)
Mon, Nov 18, 6:33 AM
Unknown Object (File)
Mon, Nov 18, 6:26 AM
Unknown Object (File)
Mon, Nov 18, 6:25 AM
Unknown Object (File)
Mon, Nov 18, 6:20 AM
Subscribers

Details

Summary

I looked through all of the DELETE queries in keyserver to see where we're handling deletion of threads. I found two queries (deleteThread and deleteInaccessibleThreads) that needed to be updated to handle deletion of thread avatar (AKA upload with container=threadID)


Depends on D7376

Test Plan
  1. Set image avatar for thread.
  2. Observe that container is set correctly in uploads table.
  3. Delete thread.
  4. Observe that row in uploads table has been removed.

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

atul published this revision for review.Apr 10 2023, 12:16 PM
This revision is now accepted and ready to land.Apr 10 2023, 1:24 PM

This is safe because uploads has an index on container (would be good to note this in your Test Plan)

This revision was landed with ongoing or failed builds.Apr 11 2023, 8:25 AM
This revision was automatically updated to reflect the committed changes.