Drop stale media-sync TODO comment - #2504
Conversation
The comment claimed the sync assumes FieldWorks is the source of truth and breaks once FWL adds/deletes files. That premise is outdated: FWL media uploads go through the upload endpoint, which writes the file to the LinkedFiles folder, commits it to hg, and records it in the DB just like a FieldWorks-added file. SyncMediaFiles reconciles the DB against the on-disk hg files, so FWL-added files are handled the same way and the comment no longer describes real behavior. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughRemoves a TODO comment before ChangesMedia Comment Cleanup
Estimated code review effort: 1 (Trivial) | ~2 minutes Suggested reviewers: Poem
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Removes a stale
TODOinMediaFileService.SyncMediaFiles.Safe to drop: the comment claimed the reconcile assumes FieldWorks is the source of truth and would break once FWL adds/deletes files. That's not true. FWL media uploads go through the upload endpoint, which writes the file into the
LinkedFilesfolder, commits it to hg, and records it in the DB, exactly like a FieldWorks-added file.SyncMediaFilesreconciles the DB against the on-disk hg files, so an FWL-added file is on disk and handled identically.