Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(public): remove getNullifierMembershipWitness #5715

Merged
merged 1 commit into from
Apr 12, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 1 addition & 15 deletions yarn-project/simulator/src/public/public_execution_context.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,4 @@
import {
type NullifierMembershipWitness,
UnencryptedFunctionL2Logs,
type UnencryptedL2Log,
} from '@aztec/circuit-types';
import { UnencryptedFunctionL2Logs, type UnencryptedL2Log } from '@aztec/circuit-types';
import {
CallContext,
FunctionData,
Expand Down Expand Up @@ -259,16 +255,6 @@ export class PublicExecutionContext extends TypedOracle {
return childExecutionResult.returnValues;
}

public async getNullifierMembershipWitness(
blockNumber: number,
nullifier: Fr,
): Promise<NullifierMembershipWitness | undefined> {
if (!this.header.globalVariables.blockNumber.equals(new Fr(blockNumber))) {
throw new Error(`Public execution oracle can only access nullifier membership witnesses for the current block`);
}
return await this.commitmentsDb.getNullifierMembershipWitnessAtLatestBlock(nullifier);
}

public async checkNullifierExists(nullifier: Fr): Promise<boolean> {
const witness = await this.commitmentsDb.getNullifierMembershipWitnessAtLatestBlock(nullifier);
return !!witness;
Expand Down
Loading