Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion yarn-project/aztec.js/src/contract/deploy_sent_tx.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ export class DeploySentTx<TContract extends Contract = Contract> extends SentTx
}

protected async getContractObject(wallet?: Wallet): Promise<TContract> {
const isWallet = (pxe: PXE | Wallet): pxe is Wallet => !!(pxe as Wallet).createTxExecutionRequest;
const isWallet = (pxe: typeof this.pxe | Wallet): pxe is Wallet => !!(pxe as Wallet).createTxExecutionRequest;
const contractWallet = wallet ?? (isWallet(this.pxe) && this.pxe);
if (!contractWallet) {
throw new Error(`A wallet is required for creating a contract instance`);
Expand Down
4 changes: 2 additions & 2 deletions yarn-project/aztec.js/src/contract/sent_tx.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { retryUntil } from '@aztec/foundation/retry';
import type { FieldsOf } from '@aztec/foundation/types';
import type { GetPublicLogsResponse, PXE } from '@aztec/stdlib/interfaces/client';
import type { AztecNode, GetPublicLogsResponse, PXE } from '@aztec/stdlib/interfaces/client';
import { type TxHash, type TxReceipt, TxStatus } from '@aztec/stdlib/tx';

/** Options related to waiting for a tx. */
Expand Down Expand Up @@ -34,7 +34,7 @@ export const DefaultWaitOpts: WaitOpts = {
* its hash, receipt, and mining status.
*/
export class SentTx {
constructor(protected pxe: PXE, protected txHashPromise: Promise<TxHash>) {}
constructor(protected pxe: PXE | AztecNode, protected txHashPromise: Promise<TxHash>) {}

/**
* Retrieves the transaction hash of the SentTx instance.
Expand Down
Loading