Files
bitvid/tests
thePR0M3TH3ANandClaude Opus 4.8 bf30233649 fix(dm): route Actions calls to the correct controller (open conversation, etc.)
The controller→Actions split left a batch of method calls in
ProfileDirectMessageActions pointing at `this` (the Actions instance)
instead of the object that actually defines them. Opening a conversation
threw "this.setFocusedDmConversation is not a function"; the same latent
bug also broke DM send-error messaging, read receipts, settings publish,
and the whole attachment flow (generate/render/reset/upload) — the user
just hadn't exercised them yet.

Route each to its real receiver:
- DM-controller methods → this.controller.*:
  handleDmSettingsPublish, describeDirectMessageSendError,
  maybePublishReadReceipt, setFocusedDmConversation
- main-controller methods → this.mainController.*:
  generateAttachmentId, renderAttachmentQueue, resetAttachmentQueue,
  uploadAttachmentQueue, clearProfileMessages

(Builds on the earlier handleDmConversationSelect delegation fix.) A static
sweep confirms every remaining `this.*` call in Actions resolves to an
Actions method or an explicit controller/mainController/helper receiver.

Test: tests/dm-conversation-select.test.mjs (cheat-resistant — drives the
real handleDmConversationSelect with stub receivers; would throw on the old
wrong-receiver code). DM unit + integration suites green; full build OK.

Co-Authored-By: Claude Opus 4.8 <[email protected]>
2026-06-16 15:07:14 -04:00
..
2026-02-21 16:08:33 -05:00
2026-02-21 15:53:09 -05:00