Skip to content

Commit

Permalink
Merge pull request #317 from bnb-chain/fix/0211v2
Browse files Browse the repository at this point in the history
fix: Change timeout to 30s to avoid api exception
  • Loading branch information
wenty22 authored Feb 12, 2025
2 parents 70c6a78 + 0d79952 commit 1845500
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion apps/canonical-bridge-server/.env.example
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
NODE_ENV=development
SERVER_PORT=3000
SERVER_TIMEOUT=5000
SERVER_TIMEOUT=30000

CMC_API_KEY=
CMC_API_ENDPOINT=https://pro-api.coinmarketcap.com
Expand Down
2 changes: 1 addition & 1 deletion apps/canonical-bridge-server/src/common/constants/index.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
export const ENDPOINT_PREFIX = 'api';
export const SERVER_PORT = parseInt(process.env.SERVER_PORT, 10) || 3000;
export const SERVER_TIMEOUT = parseInt(process.env.SERVER_TIMEOUT, 10) || 5000;
export const SERVER_TIMEOUT = parseInt(process.env.SERVER_TIMEOUT, 10) || 30 * 1000;
export const REDIS_URL = process.env.REDIS_URL;

export const CMC_API_KEY = process.env.CMC_API_KEY;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ export class AllExceptionFilter implements ExceptionFilter {
});
this.logger.error(error);

response.status(status).JSON({
response.status(status).json({
code: status,
message: `${exception}`,
});
Expand Down

0 comments on commit 1845500

Please sign in to comment.