Skip to content

Commit

Permalink
environnement variable fix
Browse files Browse the repository at this point in the history
  • Loading branch information
alkinemk committed Jul 24, 2023
1 parent 1c16f1e commit 21eacf9
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions frontend/src/components/WalletInput.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,14 @@ type ChestSalesResult = {
amount_difference: number;
};

const HEROKU_APP = process.env.HEROKU_APP;
const REACT_APP_HEROKU_APP = process.env.REACT_APP_HEROKU_APP!;

const getMissionsRewards = async (walletList: Array<string>, mode: string) => {
console.log(HEROKU_APP);
const params = new URLSearchParams();
walletList.forEach((address) => params.append("walletList", address));
params.append("mode", mode);
const response = await fetch(
`${HEROKU_APP}/api/mission_rewards?${params.toString()}`
`${REACT_APP_HEROKU_APP}/api/mission_rewards?${params.toString()}`
);
return response;
};
Expand All @@ -44,7 +43,7 @@ const getStakingRewards = async (walletList: Array<string>, mode: string) => {
params.append("mode", mode);

const response = await fetch(
`${HEROKU_APP}/api/staking_rewards?${params.toString()}`
`${REACT_APP_HEROKU_APP}/api/staking_rewards?${params.toString()}`
);
return response;
};
Expand All @@ -54,7 +53,7 @@ const getChestSales = async (walletList: Array<string>, mode: string) => {
walletList.forEach((address) => params.append("walletList", address));
params.append("mode", mode);
const response = await fetch(
`${HEROKU_APP}/api/chest_sales?${params.toString()}`
`${REACT_APP_HEROKU_APP}/api/chest_sales?${params.toString()}`
);
return response;
};
Expand Down

0 comments on commit 21eacf9

Please sign in to comment.