mirror of
https://github.com/multica-ai/multica.git
synced 2026-07-05 21:39:54 +02:00
* fix(inbox): don't archive after deleting an issue Deleting an issue from the Inbox page was calling the archive API on the inbox item right after deleteIssue succeeded. Because the inbox_item row has ON DELETE CASCADE on issue_id, it was already gone by then and the archive call 404'd with "inbox item not found", surfacing a "Failed to archive" toast. Drop the redundant archive call and invalidate the inbox cache through the issue:deleted WS handler so every tab stays in sync without an extra round trip. * fix(inbox): keep stale selection on /inbox instead of the deleted issue When another tab deletes the selected inbox issue, onInboxIssueDeleted prunes the cache and `selected` becomes null. The existing fallback then redirected to the issue detail page — which is also gone, so the user landed on a "This issue does not exist..." screen instead of back in the inbox list. Track the last key that actually resolved against the inbox list. If it used to be in the list and just disappeared, clear the selection and stay on /inbox. Only shared links that were never in the user's inbox continue to fall back to the issue detail page. Also add ws-updaters tests covering onInboxIssueDeleted and onInboxIssueStatusChanged.