Skip to content

Commit

Permalink
feat: fix token contract address when deployed to multiple chains (#142)
Browse files Browse the repository at this point in the history
  • Loading branch information
pradel authored Oct 16, 2024
1 parent f42ad0a commit 485e42d
Show file tree
Hide file tree
Showing 6 changed files with 625 additions and 590 deletions.
5 changes: 5 additions & 0 deletions .changeset/khaki-pets-fetch.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@stackspulse/server": patch
---

Fix token contract address when it's deployed to multiple chains.
6 changes: 3 additions & 3 deletions apps/server/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@
"deploy": "fly deploy --remote-only"
},
"dependencies": {
"@dotenvx/dotenvx": "1.15.0",
"@dotenvx/dotenvx": "1.19.3",
"@libsql/client": "0.8.0",
"@sentry/node": "8.33.1",
"@stacks/blockchain-api-client": "8.0.3",
"@sentry/node": "8.34.0",
"@stacks/blockchain-api-client": "8.0.4",
"@stacks/stacks-blockchain-api-types": "7.14.1",
"@stackspulse/protocols": "workspace:*",
"@t3-oss/env-core": "0.11.1",
Expand Down
5 changes: 4 additions & 1 deletion apps/server/src/api/tokens/resolve.get.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ type CoingeckoCoinsIdResponse = {
symbol: string;
name: string;
contract_address: string;
platforms?: {
stacks?: string;
};
};

type TokensResolveRouteResponse = CoingeckoCoinsIdResponse;
Expand Down Expand Up @@ -37,7 +40,7 @@ export default defineCachedEventHandler(
id: data.id,
symbol: data.symbol,
name: data.name,
contract_address: data.contract_address,
contract_address: data.platforms?.stacks || data.contract_address,
};
},
{
Expand Down
22 changes: 11 additions & 11 deletions apps/web/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,44 +10,44 @@
"deploy": "fly deploy --remote-only"
},
"dependencies": {
"@dotenvx/dotenvx": "1.15.0",
"@dotenvx/dotenvx": "1.19.3",
"@hirosystems/token-metadata-api-client": "1.3.0",
"@radix-ui/themes": "3.0.5",
"@sentry/nextjs": "8.33.1",
"@sentry/nextjs": "8.34.0",
"@stacks/stacks-blockchain-api-types": "7.14.1",
"@stacks/transactions": "6.16.1",
"@stackspulse/protocols": "workspace:*",
"@t3-oss/env-core": "0.11.1",
"@t3-oss/env-nextjs": "0.11.1",
"@tabler/icons-react": "3.19.0",
"@tanstack/react-query": "5.59.0",
"@tanstack/react-query": "5.59.15",
"class-variance-authority": "0.7.0",
"clsx": "2.1.1",
"date-fns": "4.1.0",
"fathom-client": "3.7.2",
"javascript-time-ago": "2.5.11",
"next": "14.2.14",
"next": "14.2.15",
"react": "18.3.1",
"react-dom": "18.3.1",
"recharts": "2.13.0-alpha.4",
"sharp": "0.33.5",
"tailwind-merge": "2.5.3",
"tailwind-merge": "2.5.4",
"tailwindcss-animate": "1.0.7",
"twitter-api-v2": "1.17.1",
"unstorage": "1.12.0",
"zod": "3.23.8"
},
"devDependencies": {
"@types/node": "22.7.4",
"@types/node": "22.7.5",
"@types/react": "18.3.11",
"@types/react-dom": "18.3.0",
"@types/react-dom": "18.3.1",
"autoprefixer": "10.4.20",
"eslint": "8.57.0",
"eslint-config-next": "14.2.14",
"eslint-plugin-tailwindcss": "3.17.4",
"eslint-config-next": "14.2.15",
"eslint-plugin-tailwindcss": "3.17.5",
"postcss": "8.4.47",
"radix-themes-tw": "0.2.3",
"tailwindcss": "3.4.13",
"typescript": "5.6.2"
"tailwindcss": "3.4.14",
"typescript": "5.6.3"
}
}
2 changes: 1 addition & 1 deletion packages/protocols/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@
},
"devDependencies": {
"@tsconfig/node22": "22.0.0",
"typescript": "5.6.2"
"typescript": "5.6.3"
}
}
Loading

0 comments on commit 485e42d

Please sign in to comment.