From 14c1e75c9dda8bea1de07e2067be267fc7256971 Mon Sep 17 00:00:00 2001 From: n3wbie Date: Thu, 25 May 2023 16:32:13 +0900 Subject: [PATCH] chore --- .env | 2 +- src/common/values/constant-value.ts | 2 +- .../api/selector/select-transaction-details.ts | 8 ++++---- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.env b/.env index d071fef4..0a3baac5 100644 --- a/.env +++ b/.env @@ -1,4 +1,4 @@ -NEXT_PUBLIC_API_URI='https://dev-api.gnoscan.io' +NEXT_PUBLIC_API_URI='https://api.gnoscan.io' NEXT_PUBLIC_API_VERSION = '/v2' NEXT_PUBLIC_CHAIN_NAME='Testnet 3' NEXT_PUBLIC_CHAIN_ID='test3' diff --git a/src/common/values/constant-value.ts b/src/common/values/constant-value.ts index a9a393a8..7af673fc 100644 --- a/src/common/values/constant-value.ts +++ b/src/common/values/constant-value.ts @@ -1,4 +1,4 @@ -export const API_URI = process.env.NEXT_PUBLIC_API_URI ?? 'https://dev-api.gnoscan.io'; +export const API_URI = process.env.NEXT_PUBLIC_API_URI ?? 'https://api.gnoscan.io'; export const API_VERSION = process.env.NEXT_PUBLIC_API_VERSION ?? '/v2'; export const GNO_CHAIN_NAME = process.env.NEXT_PUBLIC_CHAIN_NAME ?? 'Testnet 3'; export const GNO_CHAIN_ID = process.env.NEXT_PUBLIC_CHAIN_ID ?? 'test3'; diff --git a/src/repositories/api/selector/select-transaction-details.ts b/src/repositories/api/selector/select-transaction-details.ts index ec549c52..c2b68318 100644 --- a/src/repositories/api/selector/select-transaction-details.ts +++ b/src/repositories/api/selector/select-transaction-details.ts @@ -121,7 +121,7 @@ function decode(str: string) { const msg = original.msg; - const bodys: {[index: string]: string} = {}; + const bodies: {[index: string]: string} = {}; for (let i = 0; i < msg.length; i++) { if (msg[i]['@type'] !== '/vm.m_addpkg') continue; @@ -129,15 +129,15 @@ function decode(str: string) { const files = msg[i].package.Files; for (let j = 0; j < files.length; j++) { - bodys[`{{${i}-${j}}}`] = files[j].Body; + bodies[`{{${i}-${j}}}`] = files[j].Body; files[j] = `{{${i}-${j}}}`; } } let result = JSON.stringify(original, null, 2); - for (const key of Object.keys(bodys)) { - result = result.replace(key, bodys[key]); + for (const key of Object.keys(bodies)) { + result = result.replace(key, bodies[key]); } return result;