Repository navigation
refactor(collaboration, notifications): name the presenters' state updates instead of runInAction - #5997
Conversation
…dates instead of runInAction CommentsPresenter and NotificationsPresenter changed state after an await through inline runInAction blocks. Each block is now a named private method. makeAutoObservable makes those methods actions, so the updates still run inside one, as presenter-owns-component-state.md describes. No behaviour change. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
🚓 Slop Cop ✅ Nothing worth flagging. The diff looks consistent with the PR's stated intent and the code-style rules. The PR matches its stated intent (converting inline runInAction blocks into named private methods in two presenters), with no footprint mismatch, no secrets/artifacts, no debug leftovers, and no style-rule violations in the added code. Automated, non-blocking heads-up from an LLM. It can be wrong — use your judgment. Regenerates on every push. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info
📝 Walkthrough
Merge Risk: ⚪ Minimal · up to
|
CommentsPresenter(collaboration) andNotificationsPresenter(notifications) changed state after anawaitthrough inlinerunInActionblocks: 11 in the first, 5 in the second. Each block is now a named private method.makeAutoObservablemakes every method an action, so an update made after anawaitstill runs inside one. This is the patternai-context/code-style/presenter-owns-component-state.mddescribes. The code came over from 6.5.0 in #5955 with the inline blocks, and this cleanup was left for a separate change.No behaviour change. The methods hold exactly the assignments the blocks held, in the same order. That includes the notifications presenter's check that only the latest request writes the visible list.
Testing
yarn checkpasses for@webiny/collaborationand@webiny/notifications. Neither package has tests.Workspace: wby-next2 · 🧹 MERGE 6.5.0 => NEXT
🤖 Generated with Claude Code
Summary by CodeRabbit