@account-kit/smart-contracts 4.35.0 → 4.36.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/esm/plugindefs/session-key/config.js.map +1 -1
- package/dist/esm/src/light-account/accounts/account.js.map +1 -1
- package/dist/esm/src/light-account/accounts/base.js.map +1 -1
- package/dist/esm/src/light-account/accounts/multiOwner.js.map +1 -1
- package/dist/esm/src/light-account/accounts/predictAddress.js.map +1 -1
- package/dist/esm/src/light-account/actions/transferOwnership.d.ts +1 -1
- package/dist/esm/src/light-account/actions/transferOwnership.js.map +1 -1
- package/dist/esm/src/light-account/actions/updateOwners.js.map +1 -1
- package/dist/esm/src/light-account/clients/alchemyClient.js.map +1 -1
- package/dist/esm/src/light-account/clients/client.js.map +1 -1
- package/dist/esm/src/light-account/clients/multiOwnerAlchemyClient.js.map +1 -1
- package/dist/esm/src/light-account/clients/multiOwnerLightAccount.js.map +1 -1
- package/dist/esm/src/light-account/decorators/lightAccount.js.map +1 -1
- package/dist/esm/src/light-account/decorators/multiOwnerLightAccount.js.map +1 -1
- package/dist/esm/src/light-account/types.js.map +1 -1
- package/dist/esm/src/light-account/utils.d.ts +1 -1
- package/dist/esm/src/light-account/utils.js.map +1 -1
- package/dist/esm/src/ma-v2/account/common/modularAccountV2Base.js.map +1 -1
- package/dist/esm/src/ma-v2/account/modularAccountV2.js.map +1 -1
- package/dist/esm/src/ma-v2/account/nativeSMASigner.d.ts +2 -207
- package/dist/esm/src/ma-v2/account/nativeSMASigner.js +7 -4
- package/dist/esm/src/ma-v2/account/nativeSMASigner.js.map +1 -1
- package/dist/esm/src/ma-v2/account/predictAddress.js.map +1 -1
- package/dist/esm/src/ma-v2/actions/deferralActions.js.map +1 -1
- package/dist/esm/src/ma-v2/actions/install-validation/installValidation.js.map +1 -1
- package/dist/esm/src/ma-v2/client/client.js.map +1 -1
- package/dist/esm/src/ma-v2/modules/allowlist-module/module.js.map +1 -1
- package/dist/esm/src/ma-v2/modules/native-token-limit-module/module.js.map +1 -1
- package/dist/esm/src/ma-v2/modules/paymaster-guard-module/module.js.map +1 -1
- package/dist/esm/src/ma-v2/modules/single-signer-validation/module.js.map +1 -1
- package/dist/esm/src/ma-v2/modules/single-signer-validation/signer.d.ts +2 -207
- package/dist/esm/src/ma-v2/modules/single-signer-validation/signer.js +7 -4
- package/dist/esm/src/ma-v2/modules/single-signer-validation/signer.js.map +1 -1
- package/dist/esm/src/ma-v2/modules/time-range-module/module.js.map +1 -1
- package/dist/esm/src/ma-v2/modules/utils.js.map +1 -1
- package/dist/esm/src/ma-v2/modules/webauthn-validation/module.js.map +1 -1
- package/dist/esm/src/ma-v2/permissionBuilder.js.map +1 -1
- package/dist/esm/src/ma-v2/permissionBuilderErrors.js +1 -1
- package/dist/esm/src/ma-v2/permissionBuilderErrors.js.map +1 -1
- package/dist/esm/src/ma-v2/utils.js.map +1 -1
- package/dist/esm/src/msca/account/multiOwnerAccount.js.map +1 -1
- package/dist/esm/src/msca/account/multisigAccount.d.ts +1 -1
- package/dist/esm/src/msca/account/multisigAccount.js.map +1 -1
- package/dist/esm/src/msca/account-loupe/decorator.js.map +1 -1
- package/dist/esm/src/msca/account-loupe/types.js.map +1 -1
- package/dist/esm/src/msca/client/alchemyClient.js.map +1 -1
- package/dist/esm/src/msca/client/client.js.map +1 -1
- package/dist/esm/src/msca/client/multiSigAlchemyClient.js.map +1 -1
- package/dist/esm/src/msca/plugin-manager/decorator.js.map +1 -1
- package/dist/esm/src/msca/plugin-manager/installPlugin.js.map +1 -1
- package/dist/esm/src/msca/plugin-manager/uninstallPlugin.js.map +1 -1
- package/dist/esm/src/msca/plugins/multi-owner/extension.js.map +1 -1
- package/dist/esm/src/msca/plugins/multi-owner/plugin.js.map +1 -1
- package/dist/esm/src/msca/plugins/multi-owner/signer.d.ts +3 -208
- package/dist/esm/src/msca/plugins/multi-owner/signer.js.map +1 -1
- package/dist/esm/src/msca/plugins/multisig/actions/getThreshold.js.map +1 -1
- package/dist/esm/src/msca/plugins/multisig/actions/isOwnerOf.js.map +1 -1
- package/dist/esm/src/msca/plugins/multisig/actions/proposeUserOperation.js.map +1 -1
- package/dist/esm/src/msca/plugins/multisig/actions/readOwners.js.map +1 -1
- package/dist/esm/src/msca/plugins/multisig/actions/signMultisigUserOperation.js.map +1 -1
- package/dist/esm/src/msca/plugins/multisig/extension.js.map +1 -1
- package/dist/esm/src/msca/plugins/multisig/middleware.js.map +1 -1
- package/dist/esm/src/msca/plugins/multisig/plugin.js.map +1 -1
- package/dist/esm/src/msca/plugins/multisig/signer.d.ts +3 -208
- package/dist/esm/src/msca/plugins/multisig/signer.js.map +1 -1
- package/dist/esm/src/msca/plugins/multisig/types.js.map +1 -1
- package/dist/esm/src/msca/plugins/multisig/utils/formatSignatures.js.map +1 -1
- package/dist/esm/src/msca/plugins/multisig/utils/getSignerType.d.ts +1 -1
- package/dist/esm/src/msca/plugins/multisig/utils/getSignerType.js.map +1 -1
- package/dist/esm/src/msca/plugins/multisig/utils/splitAggregatedSignature.d.ts +1 -1
- package/dist/esm/src/msca/plugins/multisig/utils/splitAggregatedSignature.js.map +1 -1
- package/dist/esm/src/msca/plugins/session-key/extension.js.map +1 -1
- package/dist/esm/src/msca/plugins/session-key/permissions.js.map +1 -1
- package/dist/esm/src/msca/plugins/session-key/plugin.js.map +1 -1
- package/dist/esm/src/msca/plugins/session-key/signer.d.ts +4 -209
- package/dist/esm/src/msca/plugins/session-key/signer.js.map +1 -1
- package/dist/esm/src/msca/plugins/session-key/utils.js.map +1 -1
- package/dist/esm/src/msca/plugins/types.js.map +1 -1
- package/dist/esm/src/msca/utils.js.map +1 -1
- package/dist/types/src/light-account/accounts/account.d.ts.map +1 -1
- package/dist/types/src/light-account/accounts/base.d.ts.map +1 -1
- package/dist/types/src/light-account/accounts/multiOwner.d.ts.map +1 -1
- package/dist/types/src/light-account/actions/transferOwnership.d.ts +1 -1
- package/dist/types/src/light-account/actions/transferOwnership.d.ts.map +1 -1
- package/dist/types/src/light-account/actions/updateOwners.d.ts.map +1 -1
- package/dist/types/src/light-account/types.d.ts.map +1 -1
- package/dist/types/src/light-account/utils.d.ts +1 -1
- package/dist/types/src/light-account/utils.d.ts.map +1 -1
- package/dist/types/src/ma-v2/account/nativeSMASigner.d.ts +2 -207
- package/dist/types/src/ma-v2/account/nativeSMASigner.d.ts.map +1 -1
- package/dist/types/src/ma-v2/modules/allowlist-module/module.d.ts.map +1 -1
- package/dist/types/src/ma-v2/modules/single-signer-validation/signer.d.ts +2 -207
- package/dist/types/src/ma-v2/modules/single-signer-validation/signer.d.ts.map +1 -1
- package/dist/types/src/ma-v2/modules/utils.d.ts.map +1 -1
- package/dist/types/src/ma-v2/permissionBuilderErrors.d.ts.map +1 -1
- package/dist/types/src/ma-v2/utils.d.ts.map +1 -1
- package/dist/types/src/msca/account/multisigAccount.d.ts +1 -1
- package/dist/types/src/msca/account/multisigAccount.d.ts.map +1 -1
- package/dist/types/src/msca/plugin-manager/decorator.d.ts.map +1 -1
- package/dist/types/src/msca/plugin-manager/installPlugin.d.ts.map +1 -1
- package/dist/types/src/msca/plugin-manager/uninstallPlugin.d.ts.map +1 -1
- package/dist/types/src/msca/plugins/multi-owner/plugin.d.ts.map +1 -1
- package/dist/types/src/msca/plugins/multi-owner/signer.d.ts +3 -208
- package/dist/types/src/msca/plugins/multi-owner/signer.d.ts.map +1 -1
- package/dist/types/src/msca/plugins/multisig/actions/proposeUserOperation.d.ts.map +1 -1
- package/dist/types/src/msca/plugins/multisig/plugin.d.ts.map +1 -1
- package/dist/types/src/msca/plugins/multisig/signer.d.ts +3 -208
- package/dist/types/src/msca/plugins/multisig/signer.d.ts.map +1 -1
- package/dist/types/src/msca/plugins/multisig/types.d.ts.map +1 -1
- package/dist/types/src/msca/plugins/multisig/utils/formatSignatures.d.ts.map +1 -1
- package/dist/types/src/msca/plugins/multisig/utils/getSignerType.d.ts +1 -1
- package/dist/types/src/msca/plugins/multisig/utils/getSignerType.d.ts.map +1 -1
- package/dist/types/src/msca/plugins/multisig/utils/splitAggregatedSignature.d.ts +1 -1
- package/dist/types/src/msca/plugins/multisig/utils/splitAggregatedSignature.d.ts.map +1 -1
- package/dist/types/src/msca/plugins/session-key/extension.d.ts.map +1 -1
- package/dist/types/src/msca/plugins/session-key/plugin.d.ts.map +1 -1
- package/dist/types/src/msca/plugins/session-key/signer.d.ts +4 -209
- package/dist/types/src/msca/plugins/session-key/signer.d.ts.map +1 -1
- package/dist/types/src/msca/utils.d.ts.map +1 -1
- package/package.json +7 -9
- package/plugindefs/session-key/config.ts +1 -1
- package/src/light-account/accounts/account.ts +7 -5
- package/src/light-account/accounts/base.ts +18 -15
- package/src/light-account/accounts/multiOwner.ts +9 -6
- package/src/light-account/accounts/predictAddress.ts +5 -5
- package/src/light-account/actions/transferOwnership.ts +5 -4
- package/src/light-account/actions/updateOwners.ts +6 -5
- package/src/light-account/clients/alchemyClient.ts +3 -3
- package/src/light-account/clients/client.ts +6 -6
- package/src/light-account/clients/multiOwnerAlchemyClient.ts +3 -3
- package/src/light-account/clients/multiOwnerLightAccount.ts +7 -7
- package/src/light-account/decorators/lightAccount.ts +4 -4
- package/src/light-account/decorators/multiOwnerLightAccount.ts +4 -4
- package/src/light-account/types.ts +3 -2
- package/src/light-account/utils.ts +10 -10
- package/src/ma-v2/account/common/modularAccountV2Base.ts +8 -8
- package/src/ma-v2/account/modularAccountV2.ts +4 -4
- package/src/ma-v2/account/nativeSMASigner.ts +16 -13
- package/src/ma-v2/account/predictAddress.ts +13 -13
- package/src/ma-v2/actions/deferralActions.ts +7 -7
- package/src/ma-v2/actions/install-validation/installValidation.ts +14 -14
- package/src/ma-v2/client/client.ts +8 -8
- package/src/ma-v2/modules/allowlist-module/module.ts +5 -5
- package/src/ma-v2/modules/native-token-limit-module/module.ts +1 -1
- package/src/ma-v2/modules/paymaster-guard-module/module.ts +2 -2
- package/src/ma-v2/modules/single-signer-validation/module.ts +2 -2
- package/src/ma-v2/modules/single-signer-validation/signer.ts +14 -11
- package/src/ma-v2/modules/time-range-module/module.ts +6 -6
- package/src/ma-v2/modules/utils.ts +4 -4
- package/src/ma-v2/modules/webauthn-validation/module.ts +2 -2
- package/src/ma-v2/permissionBuilder.ts +14 -14
- package/src/ma-v2/permissionBuilderErrors.ts +9 -7
- package/src/ma-v2/utils.ts +4 -4
- package/src/msca/account/multiOwnerAccount.ts +5 -5
- package/src/msca/account/multisigAccount.ts +6 -6
- package/src/msca/account-loupe/decorator.ts +11 -11
- package/src/msca/account-loupe/types.ts +1 -1
- package/src/msca/client/alchemyClient.ts +4 -4
- package/src/msca/client/client.ts +12 -12
- package/src/msca/client/multiSigAlchemyClient.ts +4 -4
- package/src/msca/plugin-manager/decorator.ts +6 -5
- package/src/msca/plugin-manager/installPlugin.ts +8 -7
- package/src/msca/plugin-manager/uninstallPlugin.ts +6 -5
- package/src/msca/plugins/multi-owner/extension.ts +10 -10
- package/src/msca/plugins/multi-owner/plugin.ts +21 -19
- package/src/msca/plugins/multi-owner/signer.ts +4 -4
- package/src/msca/plugins/multisig/actions/getThreshold.ts +3 -3
- package/src/msca/plugins/multisig/actions/isOwnerOf.ts +2 -2
- package/src/msca/plugins/multisig/actions/proposeUserOperation.ts +4 -3
- package/src/msca/plugins/multisig/actions/readOwners.ts +3 -3
- package/src/msca/plugins/multisig/actions/signMultisigUserOperation.ts +5 -5
- package/src/msca/plugins/multisig/extension.ts +16 -16
- package/src/msca/plugins/multisig/middleware.ts +2 -2
- package/src/msca/plugins/multisig/plugin.ts +21 -19
- package/src/msca/plugins/multisig/signer.ts +5 -5
- package/src/msca/plugins/multisig/types.ts +4 -2
- package/src/msca/plugins/multisig/utils/formatSignatures.ts +1 -1
- package/src/msca/plugins/multisig/utils/getSignerType.ts +2 -2
- package/src/msca/plugins/multisig/utils/splitAggregatedSignature.ts +7 -6
- package/src/msca/plugins/session-key/extension.ts +16 -14
- package/src/msca/plugins/session-key/permissions.ts +7 -7
- package/src/msca/plugins/session-key/plugin.ts +30 -28
- package/src/msca/plugins/session-key/signer.ts +5 -5
- package/src/msca/plugins/session-key/utils.ts +4 -4
- package/src/msca/plugins/types.ts +1 -1
- package/src/msca/utils.ts +11 -11
|
@@ -28,13 +28,13 @@ import type { ModularAccountV2 } from "../account/common/modularAccountV2Base.js
|
|
|
28
28
|
export type ModularAccountV2Client<
|
|
29
29
|
TSigner extends SmartAccountSigner = SmartAccountSigner,
|
|
30
30
|
TChain extends Chain = Chain,
|
|
31
|
-
TTransport extends Transport | AlchemyTransport = Transport
|
|
31
|
+
TTransport extends Transport | AlchemyTransport = Transport,
|
|
32
32
|
> = SmartAccountClient<TTransport, TChain, ModularAccountV2<TSigner>>;
|
|
33
33
|
|
|
34
34
|
export type CreateModularAccountV2ClientParams<
|
|
35
35
|
TTransport extends Transport = Transport,
|
|
36
36
|
TChain extends Chain = Chain,
|
|
37
|
-
TSigner extends SmartAccountSigner = SmartAccountSigner
|
|
37
|
+
TSigner extends SmartAccountSigner = SmartAccountSigner,
|
|
38
38
|
> = CreateModularAccountV2Params<TTransport, TSigner> &
|
|
39
39
|
Omit<
|
|
40
40
|
SmartAccountClientConfig<TTransport, TChain>,
|
|
@@ -44,7 +44,7 @@ export type CreateModularAccountV2ClientParams<
|
|
|
44
44
|
export type CreateModularAccountV2AlchemyClientParams<
|
|
45
45
|
TTransport extends Transport = Transport,
|
|
46
46
|
TChain extends Chain = Chain,
|
|
47
|
-
TSigner extends SmartAccountSigner = SmartAccountSigner
|
|
47
|
+
TSigner extends SmartAccountSigner = SmartAccountSigner,
|
|
48
48
|
> = Omit<
|
|
49
49
|
CreateModularAccountV2ClientParams<TTransport, TChain, TSigner>,
|
|
50
50
|
"transport"
|
|
@@ -56,22 +56,22 @@ export type CreateModularAccountV2AlchemyClientParams<
|
|
|
56
56
|
|
|
57
57
|
export function createModularAccountV2Client<
|
|
58
58
|
TChain extends Chain = Chain,
|
|
59
|
-
TSigner extends SmartAccountSigner = SmartAccountSigner
|
|
59
|
+
TSigner extends SmartAccountSigner = SmartAccountSigner,
|
|
60
60
|
>(
|
|
61
61
|
args: CreateModularAccountV2AlchemyClientParams<
|
|
62
62
|
AlchemyTransport,
|
|
63
63
|
TChain,
|
|
64
64
|
TSigner
|
|
65
|
-
|
|
65
|
+
>,
|
|
66
66
|
): Promise<ModularAccountV2Client<TSigner, TChain, AlchemyTransport>>;
|
|
67
67
|
|
|
68
68
|
export function createModularAccountV2Client<
|
|
69
69
|
TTransport extends Transport = Transport,
|
|
70
70
|
TChain extends Chain = Chain,
|
|
71
|
-
TSigner extends SmartAccountSigner = SmartAccountSigner
|
|
71
|
+
TSigner extends SmartAccountSigner = SmartAccountSigner,
|
|
72
72
|
>(
|
|
73
73
|
args: CreateModularAccountV2ClientParams<TTransport, TChain, TSigner> &
|
|
74
|
-
NotType<TTransport, AlchemyTransport
|
|
74
|
+
NotType<TTransport, AlchemyTransport>,
|
|
75
75
|
): Promise<ModularAccountV2Client<TSigner, TChain>>;
|
|
76
76
|
|
|
77
77
|
/**
|
|
@@ -108,7 +108,7 @@ export function createModularAccountV2Client<
|
|
|
108
108
|
export async function createModularAccountV2Client(
|
|
109
109
|
config:
|
|
110
110
|
| CreateModularAccountV2ClientParams
|
|
111
|
-
| CreateModularAccountV2AlchemyClientParams
|
|
111
|
+
| CreateModularAccountV2AlchemyClientParams,
|
|
112
112
|
): Promise<SmartAccountClient | AlchemySmartAccountClient> {
|
|
113
113
|
const { transport, chain } = config;
|
|
114
114
|
|
|
@@ -15,7 +15,7 @@ export const AllowlistModule = {
|
|
|
15
15
|
selectors: Array<Hex>;
|
|
16
16
|
}>;
|
|
17
17
|
},
|
|
18
|
-
address: Address
|
|
18
|
+
address: Address,
|
|
19
19
|
): {
|
|
20
20
|
hookConfig: HookConfig;
|
|
21
21
|
initData: Hex;
|
|
@@ -67,9 +67,9 @@ export const AllowlistModule = {
|
|
|
67
67
|
input.hasERC20SpendLimit,
|
|
68
68
|
input.erc20SpendLimit,
|
|
69
69
|
input.selectors,
|
|
70
|
-
] as const
|
|
70
|
+
] as const,
|
|
71
71
|
),
|
|
72
|
-
]
|
|
72
|
+
],
|
|
73
73
|
);
|
|
74
74
|
},
|
|
75
75
|
|
|
@@ -108,9 +108,9 @@ export const AllowlistModule = {
|
|
|
108
108
|
input.hasERC20SpendLimit,
|
|
109
109
|
input.erc20SpendLimit,
|
|
110
110
|
input.selectors,
|
|
111
|
-
] as const
|
|
111
|
+
] as const,
|
|
112
112
|
),
|
|
113
|
-
]
|
|
113
|
+
],
|
|
114
114
|
);
|
|
115
115
|
},
|
|
116
116
|
};
|
|
@@ -17,7 +17,7 @@ export const PaymasterGuardModule = {
|
|
|
17
17
|
type: "address",
|
|
18
18
|
},
|
|
19
19
|
],
|
|
20
|
-
[entityId, paymaster]
|
|
20
|
+
[entityId, paymaster],
|
|
21
21
|
);
|
|
22
22
|
},
|
|
23
23
|
encodeOnUninstallData: (args: { entityId: number }): Hex => {
|
|
@@ -29,7 +29,7 @@ export const PaymasterGuardModule = {
|
|
|
29
29
|
type: "uint32",
|
|
30
30
|
},
|
|
31
31
|
],
|
|
32
|
-
[entityId]
|
|
32
|
+
[entityId],
|
|
33
33
|
);
|
|
34
34
|
},
|
|
35
35
|
};
|
|
@@ -5,7 +5,7 @@ export const SingleSignerValidationModule = {
|
|
|
5
5
|
const { entityId, signer } = args;
|
|
6
6
|
return encodeAbiParameters(
|
|
7
7
|
[{ type: "uint32" }, { type: "address" }],
|
|
8
|
-
[entityId, signer]
|
|
8
|
+
[entityId, signer],
|
|
9
9
|
);
|
|
10
10
|
},
|
|
11
11
|
|
|
@@ -18,7 +18,7 @@ export const SingleSignerValidationModule = {
|
|
|
18
18
|
type: "uint32",
|
|
19
19
|
},
|
|
20
20
|
],
|
|
21
|
-
[entityId]
|
|
21
|
+
[entityId],
|
|
22
22
|
);
|
|
23
23
|
},
|
|
24
24
|
};
|
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
import type { SmartAccountSigner } from "@aa-sdk/core";
|
|
2
2
|
import {
|
|
3
|
+
type Address,
|
|
4
|
+
type Chain,
|
|
5
|
+
concat,
|
|
6
|
+
concatHex,
|
|
3
7
|
hashMessage,
|
|
4
8
|
hashTypedData,
|
|
5
|
-
concatHex,
|
|
6
9
|
type Hex,
|
|
7
10
|
type SignableMessage,
|
|
8
11
|
type TypedData,
|
|
9
12
|
type TypedDataDefinition,
|
|
10
|
-
type Chain,
|
|
11
|
-
type Address,
|
|
12
|
-
concat,
|
|
13
13
|
} from "viem";
|
|
14
14
|
import {
|
|
15
15
|
getDefaultSingleSignerValidationModuleAddress,
|
|
16
16
|
SignatureType,
|
|
17
17
|
} from "../utils.js";
|
|
18
18
|
|
|
19
|
-
import {
|
|
19
|
+
import { pack1271Signature, packUOSignature } from "../../utils.js";
|
|
20
20
|
/**
|
|
21
21
|
* Creates an object with methods for generating a dummy signature, signing user operation hashes, signing messages, and signing typed data.
|
|
22
22
|
*
|
|
@@ -47,7 +47,7 @@ export const singleSignerMessageSigner = (
|
|
|
47
47
|
chain: Chain,
|
|
48
48
|
accountAddress: Address,
|
|
49
49
|
entityId: number,
|
|
50
|
-
deferredActionData?: Hex
|
|
50
|
+
deferredActionData?: Hex,
|
|
51
51
|
) => {
|
|
52
52
|
return {
|
|
53
53
|
getDummySignature: (): Hex => {
|
|
@@ -67,7 +67,7 @@ export const singleSignerMessageSigner = (
|
|
|
67
67
|
packUOSignature({
|
|
68
68
|
// orderedHookData: [],
|
|
69
69
|
validationSignature: signature,
|
|
70
|
-
})
|
|
70
|
+
}),
|
|
71
71
|
);
|
|
72
72
|
|
|
73
73
|
if (deferredActionData) {
|
|
@@ -106,14 +106,17 @@ export const singleSignerMessageSigner = (
|
|
|
106
106
|
// we don't apply the expected 1271 packing since deferred sigs use typed data sigs and don't expect the 1271 packing
|
|
107
107
|
signTypedData: async <
|
|
108
108
|
const typedData extends TypedData | Record<string, unknown>,
|
|
109
|
-
primaryType extends keyof typedData | "EIP712Domain" = keyof typedData
|
|
109
|
+
primaryType extends keyof typedData | "EIP712Domain" = keyof typedData,
|
|
110
110
|
>(
|
|
111
|
-
typedDataDefinition: TypedDataDefinition<typedData, primaryType
|
|
111
|
+
typedDataDefinition: TypedDataDefinition<typedData, primaryType>,
|
|
112
112
|
): Promise<Hex> => {
|
|
113
113
|
// the accounts domain already gives replay protection across accounts for deferred actions, so we don't need to apply another wrapping
|
|
114
114
|
const isDeferredAction =
|
|
115
|
-
typedDataDefinition
|
|
116
|
-
typedDataDefinition
|
|
115
|
+
typedDataDefinition.primaryType === "DeferredAction" &&
|
|
116
|
+
typedDataDefinition.domain != null &&
|
|
117
|
+
// @ts-expect-error the domain type I think changed in viem, so this is not working correctly (TODO: fix this)
|
|
118
|
+
"verifyingContract" in typedDataDefinition.domain &&
|
|
119
|
+
typedDataDefinition.domain.verifyingContract === accountAddress;
|
|
117
120
|
|
|
118
121
|
const validationSignature = await signer.signTypedData({
|
|
119
122
|
domain: {
|
|
@@ -11,17 +11,17 @@ export const TimeRangeModule = {
|
|
|
11
11
|
validUntil: number;
|
|
12
12
|
validAfter: number;
|
|
13
13
|
},
|
|
14
|
-
address: Address
|
|
14
|
+
address: Address,
|
|
15
15
|
): { hookConfig: HookConfig; initData: Hex } => {
|
|
16
16
|
if (installArgs.validUntil > 2 ** 48 - 1) {
|
|
17
17
|
throw new Error(
|
|
18
|
-
"TimeRangeModule.buildHook: validUntil > type(uint48).max"
|
|
18
|
+
"TimeRangeModule.buildHook: validUntil > type(uint48).max",
|
|
19
19
|
);
|
|
20
20
|
}
|
|
21
21
|
|
|
22
22
|
if (installArgs.validAfter > 2 ** 48 - 1) {
|
|
23
23
|
throw new Error(
|
|
24
|
-
"TimeRangeModule.buildHook: validAfter > type(uint48).max"
|
|
24
|
+
"TimeRangeModule.buildHook: validAfter > type(uint48).max",
|
|
25
25
|
);
|
|
26
26
|
}
|
|
27
27
|
|
|
@@ -56,7 +56,7 @@ export const TimeRangeModule = {
|
|
|
56
56
|
type: "uint48",
|
|
57
57
|
},
|
|
58
58
|
],
|
|
59
|
-
[entityId, validUntil, validAfter]
|
|
59
|
+
[entityId, validUntil, validAfter],
|
|
60
60
|
);
|
|
61
61
|
},
|
|
62
62
|
encodeOnUninstallData: (args: { entityId: number }): Hex => {
|
|
@@ -68,7 +68,7 @@ export const TimeRangeModule = {
|
|
|
68
68
|
type: "uint32",
|
|
69
69
|
},
|
|
70
70
|
],
|
|
71
|
-
[entityId]
|
|
71
|
+
[entityId],
|
|
72
72
|
);
|
|
73
73
|
},
|
|
74
74
|
encodeSetTimeRange: (args: {
|
|
@@ -90,7 +90,7 @@ export const TimeRangeModule = {
|
|
|
90
90
|
type: "uint48",
|
|
91
91
|
},
|
|
92
92
|
],
|
|
93
|
-
[entityId, validUntil, validAfter]
|
|
93
|
+
[entityId, validUntil, validAfter],
|
|
94
94
|
);
|
|
95
95
|
},
|
|
96
96
|
};
|
|
@@ -32,7 +32,7 @@ export enum SignatureType {
|
|
|
32
32
|
* @returns {Address} The webauthn validation module address associated with the specified chain ID or a default address if no specific mapping exists
|
|
33
33
|
*/
|
|
34
34
|
export const getDefaultWebauthnValidationModuleAddress = (
|
|
35
|
-
chain: Chain
|
|
35
|
+
chain: Chain,
|
|
36
36
|
): Address => {
|
|
37
37
|
switch (chain.id) {
|
|
38
38
|
// TODO: case mekong.id:
|
|
@@ -98,7 +98,7 @@ export const getDefaultTimeRangeModuleAddress = (chain: Chain): Address => {
|
|
|
98
98
|
* @returns {Address} The single signer validation module address associated with the specified chain ID or a default address if no specific mapping exists
|
|
99
99
|
*/
|
|
100
100
|
export const getDefaultSingleSignerValidationModuleAddress = (
|
|
101
|
-
chain: Chain
|
|
101
|
+
chain: Chain,
|
|
102
102
|
): Address => {
|
|
103
103
|
switch (chain.id) {
|
|
104
104
|
// TODO: case mekong.id:
|
|
@@ -132,7 +132,7 @@ export const getDefaultSingleSignerValidationModuleAddress = (
|
|
|
132
132
|
* @returns {Address} The paymaster guard module address associated with the specified chain ID or a default address if no specific mapping exists
|
|
133
133
|
*/
|
|
134
134
|
export const getDefaultPaymasterGuardModuleAddress = (
|
|
135
|
-
chain: Chain
|
|
135
|
+
chain: Chain,
|
|
136
136
|
): Address => {
|
|
137
137
|
switch (chain.id) {
|
|
138
138
|
// TODO: case mekong.id:
|
|
@@ -166,7 +166,7 @@ export const getDefaultPaymasterGuardModuleAddress = (
|
|
|
166
166
|
* @returns {Address} The native token limit module address associated with the specified chain ID or a default address if no specific mapping exists
|
|
167
167
|
*/
|
|
168
168
|
export const getDefaultNativeTokenLimitModuleAddress = (
|
|
169
|
-
chain: Chain
|
|
169
|
+
chain: Chain,
|
|
170
170
|
): Address => {
|
|
171
171
|
switch (chain.id) {
|
|
172
172
|
// TODO: case mekong.id:
|
|
@@ -9,7 +9,7 @@ export const WebAuthnValidationModule = {
|
|
|
9
9
|
const { entityId, x, y } = args;
|
|
10
10
|
return encodeAbiParameters(
|
|
11
11
|
[{ type: "uint32" }, { type: "uint256" }, { type: "uint256" }],
|
|
12
|
-
[entityId, x, y]
|
|
12
|
+
[entityId, x, y],
|
|
13
13
|
);
|
|
14
14
|
},
|
|
15
15
|
|
|
@@ -22,7 +22,7 @@ export const WebAuthnValidationModule = {
|
|
|
22
22
|
type: "uint32",
|
|
23
23
|
},
|
|
24
24
|
],
|
|
25
|
-
[entityId]
|
|
25
|
+
[entityId],
|
|
26
26
|
);
|
|
27
27
|
},
|
|
28
28
|
};
|
|
@@ -240,7 +240,7 @@ export class PermissionBuilder {
|
|
|
240
240
|
this.client = client;
|
|
241
241
|
this.validationConfig = {
|
|
242
242
|
moduleAddress: getDefaultSingleSignerValidationModuleAddress(
|
|
243
|
-
this.client.chain
|
|
243
|
+
this.client.chain,
|
|
244
244
|
),
|
|
245
245
|
entityId,
|
|
246
246
|
isUserOpValidation: true,
|
|
@@ -301,7 +301,7 @@ export class PermissionBuilder {
|
|
|
301
301
|
p.data.address === targetAddress) ||
|
|
302
302
|
(p.type === PermissionType.FUNCTIONS_ON_CONTRACT &&
|
|
303
303
|
"address" in p.data &&
|
|
304
|
-
p.data.address === targetAddress)
|
|
304
|
+
p.data.address === targetAddress),
|
|
305
305
|
);
|
|
306
306
|
|
|
307
307
|
if (existingPermissionWithSameAddress) {
|
|
@@ -359,15 +359,15 @@ export class PermissionBuilder {
|
|
|
359
359
|
validUntil: this.deadline,
|
|
360
360
|
validAfter: 0,
|
|
361
361
|
},
|
|
362
|
-
getDefaultTimeRangeModuleAddress(this.client.chain)
|
|
363
|
-
)
|
|
362
|
+
getDefaultTimeRangeModuleAddress(this.client.chain),
|
|
363
|
+
),
|
|
364
364
|
);
|
|
365
365
|
}
|
|
366
366
|
|
|
367
367
|
const installValidationCall = await this.compileRaw();
|
|
368
368
|
|
|
369
369
|
const { typedData } = await deferralActions(
|
|
370
|
-
this.client
|
|
370
|
+
this.client,
|
|
371
371
|
).createDeferredActionTypedDataObject({
|
|
372
372
|
callData: installValidationCall,
|
|
373
373
|
deadline: this.deadline,
|
|
@@ -375,7 +375,7 @@ export class PermissionBuilder {
|
|
|
375
375
|
});
|
|
376
376
|
|
|
377
377
|
const preSignatureDigest = deferralActions(
|
|
378
|
-
this.client
|
|
378
|
+
this.client,
|
|
379
379
|
).buildPreSignatureDeferredActionDigest({ typedData });
|
|
380
380
|
|
|
381
381
|
// Encode additional information to build the full pre-signature digest
|
|
@@ -396,7 +396,7 @@ export class PermissionBuilder {
|
|
|
396
396
|
// Translate all permissions into raw hooks if >0
|
|
397
397
|
if (this.permissions.length > 0) {
|
|
398
398
|
const rawHooks = this.translatePermissions(
|
|
399
|
-
this.validationConfig.entityId
|
|
399
|
+
this.validationConfig.entityId,
|
|
400
400
|
);
|
|
401
401
|
// Add the translated permissions as hooks
|
|
402
402
|
this.addHooks(rawHooks);
|
|
@@ -454,7 +454,7 @@ export class PermissionBuilder {
|
|
|
454
454
|
rawHooks[HookIdentifier.NATIVE_TOKEN_TRANSFER] = {
|
|
455
455
|
hookConfig: {
|
|
456
456
|
address: getDefaultNativeTokenLimitModuleAddress(
|
|
457
|
-
this.client.chain
|
|
457
|
+
this.client.chain,
|
|
458
458
|
),
|
|
459
459
|
entityId,
|
|
460
460
|
hookType: HookType.EXECUTION,
|
|
@@ -531,7 +531,7 @@ export class PermissionBuilder {
|
|
|
531
531
|
rawHooks[HookIdentifier.GAS_LIMIT] = {
|
|
532
532
|
hookConfig: {
|
|
533
533
|
address: getDefaultNativeTokenLimitModuleAddress(
|
|
534
|
-
this.client.chain
|
|
534
|
+
this.client.chain,
|
|
535
535
|
),
|
|
536
536
|
entityId,
|
|
537
537
|
hookType: HookType.VALIDATION,
|
|
@@ -654,7 +654,7 @@ export class PermissionBuilder {
|
|
|
654
654
|
|
|
655
655
|
// Only add the selectors if they aren't already in this.selectors
|
|
656
656
|
const newSelectors = selectorsToAdd.filter(
|
|
657
|
-
(selector) => !this.selectors.includes(selector)
|
|
657
|
+
(selector) => !this.selectors.includes(selector),
|
|
658
658
|
);
|
|
659
659
|
|
|
660
660
|
this.selectors = [...this.selectors, ...newSelectors];
|
|
@@ -669,7 +669,7 @@ export class PermissionBuilder {
|
|
|
669
669
|
this.hooks.push({
|
|
670
670
|
hookConfig: rawHooks[HookIdentifier.NATIVE_TOKEN_TRANSFER].hookConfig,
|
|
671
671
|
initData: NativeTokenLimitModule.encodeOnInstallData(
|
|
672
|
-
rawHooks[HookIdentifier.NATIVE_TOKEN_TRANSFER].initData
|
|
672
|
+
rawHooks[HookIdentifier.NATIVE_TOKEN_TRANSFER].initData,
|
|
673
673
|
),
|
|
674
674
|
});
|
|
675
675
|
}
|
|
@@ -678,7 +678,7 @@ export class PermissionBuilder {
|
|
|
678
678
|
this.hooks.push({
|
|
679
679
|
hookConfig: rawHooks[HookIdentifier.ERC20_TOKEN_TRANSFER].hookConfig,
|
|
680
680
|
initData: AllowlistModule.encodeOnInstallData(
|
|
681
|
-
rawHooks[HookIdentifier.ERC20_TOKEN_TRANSFER].initData
|
|
681
|
+
rawHooks[HookIdentifier.ERC20_TOKEN_TRANSFER].initData,
|
|
682
682
|
),
|
|
683
683
|
});
|
|
684
684
|
}
|
|
@@ -687,7 +687,7 @@ export class PermissionBuilder {
|
|
|
687
687
|
this.hooks.push({
|
|
688
688
|
hookConfig: rawHooks[HookIdentifier.GAS_LIMIT].hookConfig,
|
|
689
689
|
initData: NativeTokenLimitModule.encodeOnInstallData(
|
|
690
|
-
rawHooks[HookIdentifier.GAS_LIMIT].initData
|
|
690
|
+
rawHooks[HookIdentifier.GAS_LIMIT].initData,
|
|
691
691
|
),
|
|
692
692
|
});
|
|
693
693
|
}
|
|
@@ -696,7 +696,7 @@ export class PermissionBuilder {
|
|
|
696
696
|
this.hooks.push({
|
|
697
697
|
hookConfig: rawHooks[HookIdentifier.PREVAL_ALLOWLIST].hookConfig,
|
|
698
698
|
initData: AllowlistModule.encodeOnInstallData(
|
|
699
|
-
rawHooks[HookIdentifier.PREVAL_ALLOWLIST].initData
|
|
699
|
+
rawHooks[HookIdentifier.PREVAL_ALLOWLIST].initData,
|
|
700
700
|
),
|
|
701
701
|
});
|
|
702
702
|
}
|
|
@@ -13,7 +13,7 @@ export class RootPermissionOnlyError extends PermissionBuilderError {
|
|
|
13
13
|
*/
|
|
14
14
|
constructor(permission: Permission) {
|
|
15
15
|
super(
|
|
16
|
-
`Adding ${permission.type}: Cannot add permissions with ROOT permission
|
|
16
|
+
`Adding ${permission.type}: Cannot add permissions with ROOT permission`,
|
|
17
17
|
);
|
|
18
18
|
}
|
|
19
19
|
}
|
|
@@ -28,7 +28,7 @@ export class AccountAddressAsTargetError extends PermissionBuilderError {
|
|
|
28
28
|
*/
|
|
29
29
|
constructor(permission: Permission) {
|
|
30
30
|
super(
|
|
31
|
-
`${permission.type}: Account address as target, use ACCOUNT_FUNCTIONS for account address
|
|
31
|
+
`${permission.type}: Account address as target, use ACCOUNT_FUNCTIONS for account address`,
|
|
32
32
|
);
|
|
33
33
|
}
|
|
34
34
|
}
|
|
@@ -44,7 +44,7 @@ export class DuplicateTargetAddressError extends PermissionBuilderError {
|
|
|
44
44
|
*/
|
|
45
45
|
constructor(permission: Permission, targetAddress: Address) {
|
|
46
46
|
super(
|
|
47
|
-
`${permission.type}: Address ${targetAddress} already has a permission. Cannot add multiple CONTRACT_ACCESS or FUNCTIONS_ON_CONTRACT permissions for the same target address
|
|
47
|
+
`${permission.type}: Address ${targetAddress} already has a permission. Cannot add multiple CONTRACT_ACCESS or FUNCTIONS_ON_CONTRACT permissions for the same target address.`,
|
|
48
48
|
);
|
|
49
49
|
}
|
|
50
50
|
}
|
|
@@ -73,7 +73,7 @@ export class ExpiredDeadlineError extends PermissionBuilderError {
|
|
|
73
73
|
*/
|
|
74
74
|
constructor(deadline: number, currentTime: number) {
|
|
75
75
|
super(
|
|
76
|
-
`compileDeferred(): deadline ${deadline} cannot be before now (${currentTime})
|
|
76
|
+
`compileDeferred(): deadline ${deadline} cannot be before now (${currentTime})`,
|
|
77
77
|
);
|
|
78
78
|
}
|
|
79
79
|
}
|
|
@@ -88,7 +88,7 @@ export class DeadlineOverLimitError extends PermissionBuilderError {
|
|
|
88
88
|
*/
|
|
89
89
|
constructor(deadline: number) {
|
|
90
90
|
super(
|
|
91
|
-
`compileDeferred(): deadline ${deadline} cannot be > max uint48 (2^48 - 1)
|
|
91
|
+
`compileDeferred(): deadline ${deadline} cannot be > max uint48 (2^48 - 1)`,
|
|
92
92
|
);
|
|
93
93
|
}
|
|
94
94
|
}
|
|
@@ -100,7 +100,9 @@ export class ValidationConfigUnsetError extends PermissionBuilderError {
|
|
|
100
100
|
* Constructor for initializing an error message indicating the validation config is unset.
|
|
101
101
|
*/
|
|
102
102
|
constructor() {
|
|
103
|
-
super(
|
|
103
|
+
super(
|
|
104
|
+
"Missing permission among: functions on contract, functions on all contracts, account functions, contract access, or erc20 token transfer",
|
|
105
|
+
);
|
|
104
106
|
}
|
|
105
107
|
}
|
|
106
108
|
|
|
@@ -114,7 +116,7 @@ export class MultipleNativeTokenTransferError extends PermissionBuilderError {
|
|
|
114
116
|
*/
|
|
115
117
|
constructor(permission: Permission) {
|
|
116
118
|
super(
|
|
117
|
-
`${permission.type}: Must have at most ONE native token transfer permission
|
|
119
|
+
`${permission.type}: Must have at most ONE native token transfer permission`,
|
|
118
120
|
);
|
|
119
121
|
}
|
|
120
122
|
}
|
package/src/ma-v2/utils.ts
CHANGED
|
@@ -166,7 +166,7 @@ export type GetMAV2UpgradeToData<
|
|
|
166
166
|
TSigner extends SmartAccountSigner = SmartAccountSigner,
|
|
167
167
|
TAccount extends
|
|
168
168
|
| SmartContractAccountWithSigner<string, TSigner>
|
|
169
|
-
| undefined = SmartContractAccountWithSigner<string, TSigner> | undefined
|
|
169
|
+
| undefined = SmartContractAccountWithSigner<string, TSigner> | undefined,
|
|
170
170
|
> = GetAccountParameter<TAccount>;
|
|
171
171
|
|
|
172
172
|
/**
|
|
@@ -191,10 +191,10 @@ export async function getMAV2UpgradeToData<
|
|
|
191
191
|
TSigner extends SmartAccountSigner = SmartAccountSigner,
|
|
192
192
|
TAccount extends
|
|
193
193
|
| SmartContractAccountWithSigner<string, TSigner>
|
|
194
|
-
| undefined = SmartContractAccountWithSigner<string, TSigner> | undefined
|
|
194
|
+
| undefined = SmartContractAccountWithSigner<string, TSigner> | undefined,
|
|
195
195
|
>(
|
|
196
196
|
client: SmartAccountClient<TTransport, TChain, TAccount>,
|
|
197
|
-
args: GetMAV2UpgradeToData<TSigner, TAccount
|
|
197
|
+
args: GetMAV2UpgradeToData<TSigner, TAccount>,
|
|
198
198
|
): Promise<
|
|
199
199
|
UpgradeToData & {
|
|
200
200
|
createModularAccountV2FromExisting: () => Promise<
|
|
@@ -269,7 +269,7 @@ export const buildFullNonceKey = ({
|
|
|
269
269
|
|
|
270
270
|
// Parses out the 3 components from a deferred action
|
|
271
271
|
export const parseDeferredAction = (
|
|
272
|
-
deferredAction: Hex
|
|
272
|
+
deferredAction: Hex,
|
|
273
273
|
): {
|
|
274
274
|
entityId: number;
|
|
275
275
|
isGlobalValidation: boolean;
|
|
@@ -25,7 +25,7 @@ import { getDefaultMultiOwnerModularAccountFactoryAddress } from "../utils.js";
|
|
|
25
25
|
import { standardExecutor } from "./standardExecutor.js";
|
|
26
26
|
|
|
27
27
|
export type MultiOwnerModularAccount<
|
|
28
|
-
TSigner extends SmartAccountSigner = SmartAccountSigner
|
|
28
|
+
TSigner extends SmartAccountSigner = SmartAccountSigner,
|
|
29
29
|
> = SmartContractAccountWithSigner<
|
|
30
30
|
"MultiOwnerModularAccount",
|
|
31
31
|
TSigner,
|
|
@@ -36,7 +36,7 @@ export type MultiOwnerModularAccount<
|
|
|
36
36
|
export type CreateMultiOwnerModularAccountParams<
|
|
37
37
|
TTransport extends Transport = Transport,
|
|
38
38
|
TSigner extends SmartAccountSigner = SmartAccountSigner,
|
|
39
|
-
TEntryPointVersion extends "0.6.0" = "0.6.0"
|
|
39
|
+
TEntryPointVersion extends "0.6.0" = "0.6.0",
|
|
40
40
|
> = Pick<
|
|
41
41
|
ToSmartContractAccountParams<
|
|
42
42
|
"MultiOwnerModularAccount",
|
|
@@ -57,9 +57,9 @@ export type CreateMultiOwnerModularAccountParams<
|
|
|
57
57
|
|
|
58
58
|
export async function createMultiOwnerModularAccount<
|
|
59
59
|
TTransport extends Transport = Transport,
|
|
60
|
-
TSigner extends SmartAccountSigner = SmartAccountSigner
|
|
60
|
+
TSigner extends SmartAccountSigner = SmartAccountSigner,
|
|
61
61
|
>(
|
|
62
|
-
config: CreateMultiOwnerModularAccountParams<TTransport, TSigner
|
|
62
|
+
config: CreateMultiOwnerModularAccountParams<TTransport, TSigner>,
|
|
63
63
|
): Promise<MultiOwnerModularAccount<TSigner>>;
|
|
64
64
|
|
|
65
65
|
/**
|
|
@@ -84,7 +84,7 @@ export async function createMultiOwnerModularAccount<
|
|
|
84
84
|
* @returns {Promise<MultiOwnerModularAccount>} A promise that resolves to a `MultiOwnerModularAccount` object containing the created account information and methods
|
|
85
85
|
*/
|
|
86
86
|
export async function createMultiOwnerModularAccount(
|
|
87
|
-
config: CreateMultiOwnerModularAccountParams
|
|
87
|
+
config: CreateMultiOwnerModularAccountParams,
|
|
88
88
|
): Promise<MultiOwnerModularAccount> {
|
|
89
89
|
const {
|
|
90
90
|
transport,
|
|
@@ -26,7 +26,7 @@ import { standardExecutor } from "./standardExecutor.js";
|
|
|
26
26
|
export const MULTISIG_ACCOUNT_SOURCE = "MultisigModularAccount";
|
|
27
27
|
|
|
28
28
|
export type MultisigModularAccount<
|
|
29
|
-
TSigner extends SmartAccountSigner = SmartAccountSigner
|
|
29
|
+
TSigner extends SmartAccountSigner = SmartAccountSigner,
|
|
30
30
|
> = SmartContractAccountWithSigner<
|
|
31
31
|
typeof MULTISIG_ACCOUNT_SOURCE,
|
|
32
32
|
TSigner,
|
|
@@ -38,7 +38,7 @@ export type MultisigModularAccount<
|
|
|
38
38
|
export type CreateMultisigModularAccountParams<
|
|
39
39
|
TTransport extends Transport = Transport,
|
|
40
40
|
TSigner extends SmartAccountSigner = SmartAccountSigner,
|
|
41
|
-
TEntryPointVersion extends "0.6.0" = "0.6.0"
|
|
41
|
+
TEntryPointVersion extends "0.6.0" = "0.6.0",
|
|
42
42
|
> = Pick<
|
|
43
43
|
ToSmartContractAccountParams<
|
|
44
44
|
"MultisigModularAccount",
|
|
@@ -59,9 +59,9 @@ export type CreateMultisigModularAccountParams<
|
|
|
59
59
|
|
|
60
60
|
export async function createMultisigModularAccount<
|
|
61
61
|
TTransport extends Transport = Transport,
|
|
62
|
-
TSigner extends SmartAccountSigner = SmartAccountSigner
|
|
62
|
+
TSigner extends SmartAccountSigner = SmartAccountSigner,
|
|
63
63
|
>(
|
|
64
|
-
config: CreateMultisigModularAccountParams<TTransport, TSigner
|
|
64
|
+
config: CreateMultisigModularAccountParams<TTransport, TSigner>,
|
|
65
65
|
): Promise<MultisigModularAccount<TSigner>>;
|
|
66
66
|
|
|
67
67
|
/**
|
|
@@ -87,7 +87,7 @@ export async function createMultisigModularAccount<
|
|
|
87
87
|
* @returns {Promise<MultisigModularAccount>} A promise that resolves to a `MultisigModularAccount` object containing the created account information and methods.
|
|
88
88
|
*/
|
|
89
89
|
export async function createMultisigModularAccount(
|
|
90
|
-
config: CreateMultisigModularAccountParams
|
|
90
|
+
config: CreateMultisigModularAccountParams,
|
|
91
91
|
): Promise<MultisigModularAccount> {
|
|
92
92
|
const {
|
|
93
93
|
transport,
|
|
@@ -166,7 +166,7 @@ export async function createMultisigModularAccount(
|
|
|
166
166
|
}
|
|
167
167
|
|
|
168
168
|
export const isMultisigModularAccount = (
|
|
169
|
-
acct: SmartContractAccount
|
|
169
|
+
acct: SmartContractAccount,
|
|
170
170
|
): acct is MultisigModularAccount => {
|
|
171
171
|
return acct.source === MULTISIG_ACCOUNT_SOURCE;
|
|
172
172
|
};
|