Skip to content

Commit

Permalink
Fix login to always use the correct chain based on production environ…
Browse files Browse the repository at this point in the history
…ment settings
  • Loading branch information
Royal-lobster committed Sep 6, 2024
1 parent ff9ed69 commit 55a2eae
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/serious-points-check.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@everipedia/iq-login": patch
---

Fixes login always uses polygon chain
3 changes: 2 additions & 1 deletion src/components/IqLoginProvider.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@ if (!process.env.NEXT_PUBLIC_IS_PRODUCTION) {
console.log("NEXT_PUBLIC_IS_PRODUCTION is not set");
}

const chain = process.env.NEXT_PUBLIC_IS_PRODUCTION ? polygon : iqTestnet;
const chain =
process.env.NEXT_PUBLIC_IS_PRODUCTION === "true" ? polygon : iqTestnet;

export const defaultConfig = getDefaultConfig({
appName: "IQ.Wiki AI Editor",
Expand Down

0 comments on commit 55a2eae

Please sign in to comment.