Repository navigation
fix(drafts): preserve reply drafts across forum moves - #460
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Reply drafts were stored under the old forum after a thread move, hiding them from the composer and allowing deletion of the old forum to delete the draft. Identify reply drafts by owner and thread, read their live forum, update stored references during moves, and save under the locked current thread forum so stale composers cannot restore the old reference. New-thread drafts retain their forum identity.
Migration 0073_reply_draft_forums repairs existing references without changing saved content or timestamps. It cannot restore drafts already deleted by earlier forum deletion. Adds database regressions for resuming, saving, removal, forum deletion, migration repair, and a real PostgreSQL two-connection move/autosave race.
Formatting, comment, and diff checks passed. Tests and migration drift validation run in CI per maintainer instruction.
Addresses post-v0.38.0 audit finding #4.