fix breaking change on null or undefined wallet (#2303)
Co-authored-by: henrye <henry@notanemail>
This commit is contained in:
parent
11af9a6624
commit
1bb1969d60
|
@ -41,6 +41,7 @@ The minor version will be incremented upon a breaking change and the patch versi
|
|||
- ts: Update seeds inference to allow nested user defined structs within the seeds ([#2198](https://github.com/coral-xyz/anchor/pull/2198))
|
||||
- event: Fix multiple event listeners with the same name. ([#2165](https://github.com/coral-xyz/anchor/pull/2165))
|
||||
- lang: Prevent the payer account from being initialized as a program account. ([#2284](https://github.com/coral-xyz/anchor/pull/2284))
|
||||
- ts: Fixing breaking change where null or undefined wallet throws an error. ([#2303](https://github.com/coral-xyz/anchor/pull/2303))
|
||||
|
||||
### Breaking
|
||||
|
||||
|
|
|
@ -60,7 +60,7 @@ export class AnchorProvider implements Provider {
|
|||
readonly wallet: Wallet,
|
||||
readonly opts: ConfirmOptions
|
||||
) {
|
||||
this.publicKey = wallet.publicKey;
|
||||
this.publicKey = wallet?.publicKey;
|
||||
}
|
||||
|
||||
static defaultOptions(): ConfirmOptions {
|
||||
|
|
Loading…
Reference in New Issue