@smithii_io/mixoor 0.0.6 → 0.0.8

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.
@@ -3,6 +3,7 @@ import { buildPoseidon } from 'circomlibjs';
3
3
  import * as fs from 'fs';
4
4
  import * as path from 'path';
5
5
  import { groth16 } from 'snarkjs';
6
+ import { fileURLToPath } from 'url';
6
7
  import { randomBytes as randomBytes$1 } from 'crypto';
7
8
 
8
9
  // src/generated/accounts/nullifierAccount.ts
@@ -1166,6 +1167,8 @@ async function generateProof(input) {
1166
1167
  pathIndices: input.pathIndices,
1167
1168
  amount: BigInt(input.amount).toString()
1168
1169
  };
1170
+ const __filename = fileURLToPath(import.meta.url);
1171
+ const __dirname = path.dirname(__filename);
1169
1172
  const packageRoot = path.join(__dirname, "../..");
1170
1173
  const wasmPath = path.join(
1171
1174
  packageRoot,
@@ -1175,9 +1178,7 @@ async function generateProof(input) {
1175
1178
  const { proof, publicSignals } = await groth16.fullProve(
1176
1179
  circuitInputs,
1177
1180
  wasmPath,
1178
- zkeyPath,
1179
- true
1180
- // ! use single thread for proving
1181
+ zkeyPath
1181
1182
  );
1182
1183
  const vKeyPath = path.join(packageRoot, "circuits/verification_key.json");
1183
1184
  const isValid = await groth16.verify(