fix: new infinite signup redirect for staging and development#1133
fix: new infinite signup redirect for staging and development#1133iamitprakash merged 5 commits intodevelopfrom
Conversation
WalkthroughModified the development HOME URL from a root path to a subdomain-based configuration using existing environment variables, and augmented LoginService redirect logic to prevent redirects when users are on the '/new-signup' path, allowing them to complete signup without being redirected away. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes Possibly related PRs
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Fix all issues with AI agents
In `@app/services/login.js`:
- Around line 35-43: The code reads window.location.pathname and calls
window.location.replace() unguarded; wrap those accesses with the FastBoot guard
already injected on the service by checking this.fastboot.isFastBoot (or its
negation) before touching window. Concretely, only compute currentPath from
window.location.pathname and call window.location.replace(AUTH.SIGN_UP) when
this.fastboot.isFastBoot is false (and keep the existing conditions
user.incompleteUserDetails and !this.featureFlag.isDevMode); alternatively wrap
the entire redirect block (the currentPath variable, the conditional using
featureFlag.isDevMode, and the call to window.location.replace) in a
not-FastBoot check so server-side rendering won’t access window.
📜 Review details
Configuration used: Organization UI
Review profile: ASSERTIVE
Plan: Pro
📒 Files selected for processing (2)
app/constants/urls.jsapp/services/login.js
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: build (18.x)
🔇 Additional comments (1)
app/constants/urls.js (1)
36-36: LGTM, but note the mixed URL pattern in development config.The change to use
https://dev.realdevsquad.comfor HOME aligns with the PR objective. This ensuresAUTH.SIGN_UPresolves to a full URL, which is necessary forwindow.location.replace()to work correctly in the login service.However, note that other development URLs (GOTO, EVENTS, PROFILE, IDENTITY, MY_STATUS) remain as relative paths while HOME is now absolute. This inconsistency is acceptable if intentional, but consider documenting this pattern or aligning all URLs for consistency in a future refactor.
✏️ Tip: You can disable this entire section by setting review_details to false in your review settings.
Deploying www-rds with
|
| Latest commit: |
e18d24c
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://d68dbce9.www-rds.pages.dev |
| Branch Preview URL: | https://fix-login-redirect.www-rds.pages.dev |
| import { setupTest } from 'website-www/tests/helpers'; | ||
| import { visit } from '@ember/test-helpers'; | ||
| import Service from '@ember/service'; | ||
|
|
There was a problem hiding this comment.
this login stub is required to prevent flaky behaviour for tests with login redirect and from browser timeout issues
8ffe062 to
7cfc531
Compare
Date: 15-01-26
Developer Name: @MayankBansal12
Issue Ticket Number:-
Description:
/new-signupIs Under Feature Flag
Database changes
Breaking changes (If your feature is breaking/missing something please mention pending tickets)
Is Development Tested?
Tested in staging?
Add relevant Screenshot below ( e.g test coverage etc. )
screencast
Screencast.from.2026-01-15.02-31-37.mp4