Switching accounts does location.reload(), which preserves history.state — so the new account re-mounted the Messages module from the previous account's _sub sub-view, whose partnerId belongs to the OLD identity (often the new account's own id → an empty self-thread). Symptom: after switching to the recipient you land on a blank thread and the just-received message never shows (F5 keeps history.state); only going back to the list and reopening the real conversation works. Fix: (1) strip _sub/_ov from history.state before the switch reload so the new account starts at the module root; (2) guard Messages so a thread view with partnerId === meId falls back to the conversation list (can't message yourself). |
||
|---|---|---|
| .. | ||
| public/welcome | ||
| src | ||
| index.html | ||
| package-lock.json | ||
| package.json | ||
| postcss.config.js | ||
| tailwind.config.js | ||
| tsconfig.json | ||
| vite.config.ts | ||