Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: return to window origin locally #230

Merged
merged 3 commits into from
Jan 31, 2025
Merged

fix: return to window origin locally #230

merged 3 commits into from
Jan 31, 2025

Conversation

deov31
Copy link
Contributor

@deov31 deov31 commented Jan 28, 2025

Jira: B2B-2203

What/Why?

Using window origin url while login in local env. Right now is creating an incorrect url for the login graphql api call. /bigcommerce/graphql

Rollout/Rollback

Revert

Testing

login to buyer portal locally

@deov31 deov31 self-assigned this Jan 28, 2025
@deov31 deov31 requested review from icatalina, LeoChowChina and a team as code owners January 28, 2025 18:21
@@ -8,7 +8,7 @@ export const {
const { VITE_IS_LOCAL_ENVIRONMENT } = import.meta.env;

const generateBcStorefrontAPIBaseUrl = () => {
if (VITE_IS_LOCAL_ENVIRONMENT === 'TRUE') return '/bigcommerce';
if (VITE_IS_LOCAL_ENVIRONMENT === 'TRUE') return window.origin;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe this is not needed anymore.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I followed your suggestion, you're right, it not needed

@deov31
Copy link
Contributor Author

deov31 commented Jan 30, 2025

image
login in a catalyst store working

@deov31 deov31 requested a review from bc-micah January 30, 2025 23:30
Copy link
Contributor

@bc-micah bc-micah left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for fixing this.

Some suggestions for fixing the tests.
fix/B2B-2203...fix/B2B-2203-improve-tests

* fix: correct the tests

* fix: clean console log

---------

Co-authored-by: Micah Thomas <[email protected]>
@deov31 deov31 merged commit af32baf into main Jan 31, 2025
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants