Skip to content

Commit

Permalink
move bigint conversion
Browse files Browse the repository at this point in the history
  • Loading branch information
StoyanD committed Dec 19, 2024
1 parent f1201f1 commit 1bfd2b7
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/balance/balance.ws.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,11 +61,12 @@ export class BalanceWebsocketService implements OnApplicationBootstrap, OnModule
addJob(network: Network, chainID: number) {
return async (logs: ViemEventLog[]) => {
const logTasks = logs.map((transferEvent) => {
//bigint as it cant serialize to json
transferEvent = convertBigIntsToStrings(transferEvent)
transferEvent.sourceChainID = BigInt(chainID)
//add network to the event
transferEvent.sourceNetwork = network
transferEvent.sourceChainID = BigInt(chainID)

//bigint as it cant serialize to json
transferEvent = convertBigIntsToStrings(transferEvent)
this.logger.debug(
EcoLogMessage.fromDefault({
message: `ws: balance transfer`,
Expand Down

0 comments on commit 1bfd2b7

Please sign in to comment.