Skip to content

Commit

Permalink
fix: fixed error get pair from contract
Browse files Browse the repository at this point in the history
  • Loading branch information
trungbach committed Sep 28, 2023
1 parent c26984d commit 919a560
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion packages/oraidex-server/package.staging.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@oraichain/oraidex-server-staging",
"version": "1.0.2",
"version": "1.0.3",
"main": "dist/index.js",
"bin": "dist/index.js",
"license": "MIT",
Expand Down
3 changes: 1 addition & 2 deletions packages/oraidex-sync/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -146,9 +146,8 @@ class OraiDexSync {
try {
console.time("timer-updateLatestPairInfos");
const pairInfos = await getAllPairInfos();

const allPools = await this.duckDb.getPools();
if (allPools.length > 0) return;
if (allPools.length > 0 && pairInfos.length === allPools.length) return;
await this.duckDb.insertPairInfos(
pairInfos.map((pair, index) => {
const symbols = getSymbolFromAsset(pair.asset_infos);
Expand Down

0 comments on commit 919a560

Please sign in to comment.