Compare commits

..

No commits in common. "79ea86823483a4eefd610d50176ca1eae283d9ab" and "af9a7582b97373b3e6960dc4b28afb1a4414630b" have entirely different histories.

1 changed files with 5 additions and 5 deletions

View File

@ -316,18 +316,18 @@ function autoResolveSpace(token: string, username: string): void {
if (!username) return;
const currentSpace = _getCurrentSpace();
const currentModule = _getCurrentModule();
if (currentSpace !== "demo" || currentModule !== "rspace") {
// User is viewing a specific page (their own space, someone else's,
// or a module on demo). Don't redirect — just reload so the
if (currentSpace !== "demo") {
// User is on a specific space (their own or someone else's).
// Provision their personal space silently in the background.
// Don't redirect — they chose to be here. Just reload so the
// authenticated session takes effect (access gates, CRDT sync).
autoProvisionSpace(token);
window.location.reload();
return;
}
// On demo dashboard (landing page) — provision personal space and redirect
// On demo/landing — provision personal space and redirect to dashboard
fetch("/api/spaces/auto-provision", {
method: "POST",
headers: {