fix(chat): redirect guests to auth before image paywall

This commit is contained in:
2026-06-24 18:41:59 +08:00
parent c288148c12
commit 5aa32a4256
4 changed files with 47 additions and 12 deletions
+7 -2
View File
@@ -133,7 +133,12 @@ export function ChatScreen() {
}
function handleUnlockImagePaywall(): void {
router.push(`${ROUTES.subscription}?type=vip`);
const subscriptionUrl = ROUTE_BUILDERS.subscription("vip");
if (isGuest) {
router.push(ROUTE_BUILDERS.authWithRedirect(subscriptionUrl));
return;
}
router.push(subscriptionUrl);
}
function handleMessageLimitUnlock(): void {
@@ -141,7 +146,7 @@ export function ChatScreen() {
router.push(ROUTES.auth);
return;
}
router.push(`${ROUTES.subscription}?type=vip`);
router.push(ROUTE_BUILDERS.subscription("vip"));
}
return (