Skip to content

Commit b27bd19

Browse files
pre signing check fixed
1 parent 0675fc1 commit b27bd19

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/mpcCoreKit.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ import {
3939
EnableMFAParams,
4040
ICoreKit,
4141
IFactorKey,
42+
IFactorManagerContext,
4243
IMPCContext,
4344
InitParams,
4445
ISignerContext,
@@ -77,7 +78,7 @@ import {
7778
scalarBNToBufferSEC1,
7879
} from "./utils";
7980

80-
export class Web3AuthMPCCoreKit implements ICoreKit, IMPCContext, ISignerContext {
81+
export class Web3AuthMPCCoreKit implements ICoreKit, IMPCContext, ISignerContext, IFactorManagerContext {
8182
public state: Web3AuthState = { accountIndex: 0 };
8283

8384
public torusSp: TSSTorusServiceProvider | null = null;
@@ -1132,7 +1133,7 @@ export class Web3AuthMPCCoreKit implements ICoreKit, IMPCContext, ISignerContext
11321133
}
11331134

11341135
public async preSetupDKLSSigningConfig(): Promise<IDklsSignConfig> {
1135-
if (!this.hasRemoteFactorInitialized || !this.state.factorKey) {
1136+
if (!this.hasRemoteFactorInitialized && !this.state.factorKey) {
11361137
throw CoreKitError.factorKeyNotPresent("Factor key or remote factor not present in state when pre-setting up DKLSSigning.");
11371138
}
11381139
const { torusNodeTSSEndpoints } = fetchLocalConfig(this.options.web3AuthNetwork, this.keyType);

0 commit comments

Comments
 (0)