diff --git a/solidity-verifiers/templates/groth16_verifier.askama.sol b/solidity-verifiers/templates/groth16_verifier.askama.sol index 5d466bd5..e8e12035 100644 --- a/solidity-verifiers/templates/groth16_verifier.askama.sol +++ b/solidity-verifiers/templates/groth16_verifier.askama.sol @@ -56,7 +56,7 @@ contract Groth16Verifier { function verifyProof(uint[2] calldata _pA, uint[2][2] calldata _pB, uint[2] calldata _pC, uint[{{ gamma_abc_len - 1 }}] calldata _pubSignals) public view returns (bool) { assembly { function checkField(v) { - if iszero(lt(v, q)) { + if iszero(lt(v, r)) { mstore(0, 0) return(0, 0x20) } @@ -166,4 +166,4 @@ contract Groth16Verifier { return(0, 0x20) } } -} \ No newline at end of file +}