Skip to content
Merged
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
4 changes: 2 additions & 2 deletions packages/contracts-sdk/src/lib/contracts-sdk.ts
Original file line number Diff line number Diff line change
Expand Up @@ -415,12 +415,12 @@ export class LitContracts {
}

this.log('Your Signer:', this.signer);
this.log('Your Provider:', this.provider.connection);
this.log('Your Provider:', this.provider?.connection!);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should we move this log under the check for this.provider being defined.

Copy link
Collaborator Author

@Ansonhkg Ansonhkg Oct 3, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You mean wrap it inside a if/else to check if 'connection' exists then print it out? If so, I don't think so, cus I'd like to see it connection is undefined in different environments when debug is on

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see, if we want to log out when this.provider is undefined then we can keep it.


if (!this.provider) {
this.log('No provider found. Will try to use the one from the signer.');
this.provider = this.signer.provider;
this.log('Your Provider(from signer):', this.provider.connection);
this.log('Your Provider(from signer):', this.provider?.connection!);
}

const addresses: any = await LitContracts.getContractAddresses(
Expand Down
Loading