Skip to content
This repository was archived by the owner on Feb 11, 2025. It is now read-only.

Commit 2084724

Browse files
committed
fix: ec import
1 parent 60e5366 commit 2084724

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

issues/oldHashAlgo/fix.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import { BigNumber } from "ethers";
22
import ora from "ora";
33
import { Provider } from "starknet-390/dist/provider";
44
import { Account as SNAccount } from "starknet-390/dist/account";
5-
import { ec } from "starknet-390/dist/utils/ellipticCurve";
5+
import { getKeyPair, getStarkKey } from "starknet-390/dist/utils/ellipticCurve";
66
import {
77
compileCalldata,
88
estimatedFeeToMaxFee,
@@ -27,8 +27,8 @@ export const fix = async (
2727
if (!privateKey) {
2828
throw new Error("No private key for account to credit");
2929
}
30-
const keyPair = ec.getKeyPair(privateKey);
31-
const starkKey = ec.getStarkKey(keyPair);
30+
const keyPair = getKeyPair(privateKey);
31+
const starkKey = getStarkKey(keyPair);
3232
if (!BigNumber.from(a.signer).eq(starkKey)) {
3333
throw new Error(
3434
"Account cant be controlled with the selected private key or seed"

0 commit comments

Comments
 (0)