Skip to content

Commit c5c7cc6

Browse files
committed
chore: update naming
1 parent 0d85ecf commit c5c7cc6

File tree

2 files changed

+9
-13
lines changed

2 files changed

+9
-13
lines changed

src/api/master/clients/enclavedExpressClient.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -604,7 +604,7 @@ export class EnclavedExpressClient {
604604
/**
605605
* Create custom MPCv2 Round 1 signing function for enclaved express client
606606
*/
607-
export function createCustomMPCv2SigningRound1Generator(
607+
export function signMPCv2Round1(
608608
enclavedExpressClient: EnclavedExpressClient,
609609
source: 'user' | 'backup',
610610
pub: string,
@@ -639,7 +639,7 @@ export function createCustomMPCv2SigningRound1Generator(
639639
/**
640640
* Create custom MPCv2 Round 2 signing function for enclaved express client
641641
*/
642-
export function createCustomMPCv2SigningRound2Generator(
642+
export function signMPCv2Round2(
643643
enclavedExpressClient: EnclavedExpressClient,
644644
source: 'user' | 'backup',
645645
pub: string,
@@ -674,7 +674,7 @@ export function createCustomMPCv2SigningRound2Generator(
674674
/**
675675
* Create custom MPCv2 Round 3 signing function for enclaved express client
676676
*/
677-
export function createCustomMPCv2SigningRound3Generator(
677+
export function signMPCv2Round3(
678678
enclavedExpressClient: EnclavedExpressClient,
679679
source: 'user' | 'backup',
680680
pub: string,

src/api/master/handlers/ecdsa.ts

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@ import {
1313
EnclavedExpressClient,
1414
SignMpcV2Round1Response,
1515
SignMpcV2Round2Response,
16-
createCustomMPCv2SigningRound1Generator,
17-
createCustomMPCv2SigningRound2Generator,
18-
createCustomMPCv2SigningRound3Generator,
16+
signMPCv2Round1,
17+
signMPCv2Round2,
18+
signMPCv2Round3,
1919
} from '../clients/enclavedExpressClient';
2020

2121
export async function handleEcdsaSigning(
@@ -36,11 +36,7 @@ export async function handleEcdsaSigning(
3636

3737
// Create custom signing methods that maintain state
3838
const customRound1Signer = async (params: { txRequest: TxRequest }) => {
39-
const response = await createCustomMPCv2SigningRound1Generator(
40-
enclavedExpressClient,
41-
source,
42-
commonKeychain,
43-
)(params);
39+
const response = await signMPCv2Round1(enclavedExpressClient, source, commonKeychain)(params);
4440
round1Response = response;
4541
return response;
4642
};
@@ -54,7 +50,7 @@ export async function handleEcdsaSigning(
5450
if (!round1Response) {
5551
throw new Error('Round 1 must be completed before Round 2');
5652
}
57-
const response = await createCustomMPCv2SigningRound2Generator(
53+
const response = await signMPCv2Round2(
5854
enclavedExpressClient,
5955
source,
6056
commonKeychain,
@@ -78,7 +74,7 @@ export async function handleEcdsaSigning(
7874
if (!round2Response) {
7975
throw new Error('Round 1 must be completed before Round 3');
8076
}
81-
return await createCustomMPCv2SigningRound3Generator(
77+
return await signMPCv2Round3(
8278
enclavedExpressClient,
8379
source,
8480
commonKeychain,

0 commit comments

Comments
 (0)