Skip to content

Commit

Permalink
feat: updated api/wallets
Browse files Browse the repository at this point in the history
  • Loading branch information
pranavkparti committed Aug 20, 2023
1 parent 38705c9 commit 156a5e1
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/api/wallets.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ const mapWallet = (walletData, nameProp) => {
logoURL: walletData.logo_url,
tokensInWallet: walletData.tokens_in_wallet,
name: walletData[nameProp],
about: walletData.about,
};
};

Expand All @@ -28,7 +29,7 @@ export const getWallets = async (name = '', pageNumber = 1) => {
})
.then((response) => {
const wallets = response.data.wallets.map((wallet) =>
mapWallet(wallet, 'name')
mapWallet(wallet, 'name'),
);
return {
total: response.data.total,
Expand Down
1 change: 1 addition & 0 deletions src/pages/Wallet/Wallet.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ const Wallet = () => {
logoURL: '',
tokensInWallet: 0,
name: '',
about: '',
};

const [wallet, setWallet] = useState(defaultWallet);
Expand Down

0 comments on commit 156a5e1

Please sign in to comment.