We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d1e7560 commit cbdb7cdCopy full SHA for cbdb7cd
packages/thirdweb/src/wallets/smart/smart-wallet.ts
@@ -129,6 +129,12 @@ import type { SmartWalletOptions } from "./types.js";
129
export function smartWallet(
130
createOptions: SmartWalletOptions,
131
): Wallet<"smart"> {
132
+ if (
133
+ typeof createOptions.factoryAddress === "undefined" &&
134
+ typeof createOptions.chain !== "undefined"
135
+ ) {
136
+ throw new Error("You must provide a chain if factory address is specified");
137
+ }
138
const emitter = createWalletEmitter<"smart">();
139
let account: Account | undefined = undefined;
140
let adminAccount: Account | undefined = undefined;
0 commit comments