Skip to content

Commit 3f8de75

Browse files
chore: format
1 parent 481c32e commit 3f8de75

1 file changed

Lines changed: 6 additions & 8 deletions

File tree

packages/txm/lib/Transaction.ts

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
import { type Hex, type UUID, bigIntReplacer, bigIntReviver, bigIntToZeroPadded, createUUID } from "@happy.tech/common"
22
import { context, trace } from "@opentelemetry/api"
33
import type { Insertable, Selectable } from "kysely"
4+
import { type Result, err, ok } from "neverthrow"
45
import { type Address, type ContractFunctionArgs, type Hash, encodeFunctionData } from "viem"
56
import type { ABIManager } from "./AbiManager"
67
import type { LatestBlock } from "./BlockMonitor"
78
import { Topics, eventBus } from "./EventBus.js"
89
import type { TransactionTable } from "./db/types.js"
910
import { TxmMetrics } from "./telemetry/metrics"
1011
import { TraceMethod } from "./telemetry/traces"
11-
import { err, ok, type Result } from "neverthrow"
1212

1313
export enum TransactionStatus {
1414
/**
@@ -283,18 +283,16 @@ export class Transaction {
283283

284284
waitForFinalization(timeout?: number): Promise<Result<Transaction, Error>> {
285285
return new Promise((resolve) => {
286-
this.waitingPromises.push(resolve);
287-
286+
this.waitingPromises.push(resolve)
287+
288288
if (timeout) {
289289
setTimeout(() => {
290-
this.waitingPromises = this.waitingPromises.filter(
291-
p => p !== resolve
292-
);
290+
this.waitingPromises = this.waitingPromises.filter((p) => p !== resolve)
293291

294292
resolve(err(new Error(`Transaction finalization timed out after ${timeout}ms`)))
295-
}, timeout);
293+
}, timeout)
296294
}
297-
});
295+
})
298296
}
299297

300298
get attemptCount(): number {

0 commit comments

Comments
 (0)