Skip to content
This repository has been archived by the owner on Dec 13, 2022. It is now read-only.

Commit

Permalink
fix block API cumulative_diff type might be number (#32)
Browse files Browse the repository at this point in the history
  • Loading branch information
williamchong authored Feb 20, 2022
1 parent e86fb5a commit 1d331e3
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/query/block.ts
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,9 @@ export async function getBlock({
// REVIEW: does assuming re-forking condition work better than fatal error?
process.exit(1);
}
if (body.cumulative_diff) { // HACK: Fix some cumulative_diff is number
body.cumulative_diff = body.cumulative_diff.toString();
}
warmNode(tryNode);
return body;
}
Expand Down

0 comments on commit 1d331e3

Please sign in to comment.