forked from tornado-packages/noble-curves
Lint
This commit is contained in:
parent
08bb00cc8f
commit
8c48abe16a
@ -27,8 +27,7 @@ export function validateOpts(opts: PoseidonOpts) {
|
||||
// Default is 5, but for some reasons stark uses 3
|
||||
let { sboxPower } = opts;
|
||||
if (sboxPower === undefined) sboxPower = 5;
|
||||
if (!([3, 5, 7].includes(sboxPower)))
|
||||
throw new Error(`Poseidon wrong sboxPower=${sboxPower}`);
|
||||
if (![3, 5, 7].includes(sboxPower)) throw new Error(`Poseidon wrong sboxPower=${sboxPower}`);
|
||||
|
||||
const _sboxPower = BigInt(sboxPower);
|
||||
let sboxFn = (n: bigint) => FpPow(Fp, n, _sboxPower);
|
||||
|
Loading…
Reference in New Issue
Block a user