Skip to content

Commit

Permalink
fix: env names (#681)
Browse files Browse the repository at this point in the history
  • Loading branch information
albertfolch-redeemeum authored Mar 15, 2024
1 parent 7ea47c7 commit fc972d2
Showing 1 changed file with 13 additions and 4 deletions.
17 changes: 13 additions & 4 deletions packages/react-kit/src/lib/config/config.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,21 @@
import { getRpcUrls } from "../const/networks";

const magicLinkKey = process.env.STORYBOOK_REACT_APP_MAGIC_API_KEY;
const magicLinkKey =
process.env.STORYBOOK_REACT_APP_MAGIC_API_KEY ||
process.env.REACT_APP_MAGIC_API_KEY;
if (!magicLinkKey) {
throw new Error("STORYBOOK_REACT_APP_MAGIC_API_KEY is not defined");
throw new Error(
"STORYBOOK_REACT_APP_MAGIC_API_KEY/REACT_APP_MAGIC_API_KEY is not defined"
);
}
const infuraKey = process.env.STORYBOOK_INFURA_PROJECT_SECRET;
const infuraKey =
process.env.STORYBOOK_INFURA_PROJECT_SECRET ||
process.env.INFURA_PROJECT_SECRET ||
process.env.REACT_APP_INFURA_IPFS_PROJECT_SECRET;
if (!infuraKey) {
throw new Error("STORYBOOK_INFURA_PROJECT_SECRET is not defined");
throw new Error(
"STORYBOOK_INFURA_PROJECT_SECRET/INFURA_PROJECT_SECRET/REACT_APP_INFURA_IPFS_PROJECT_SECRET is not defined"
);
}

export const CONFIG = {
Expand Down

0 comments on commit fc972d2

Please sign in to comment.