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

sort query hashes before compare #81

Merged
merged 3 commits into from
Feb 5, 2024
Merged

Conversation

volodymyr-basiuk
Copy link
Collaborator

No description provided.

@@ -73,4 +81,10 @@ export class LinkedMultiQueryVerifier implements PubSignalsVerifier {
async verifyStates(): Promise<void> {
return Promise.resolve();
}

private bigIntCompare = (a: bigint, b: bigint): number => {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

=> a-b

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sort expects number as return tupe (a-b will return BigInt), could be something like this a<b?-1:(a>b?1:0)

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, no in that case it's fine

@vmidyllic vmidyllic merged commit 8fbeb18 into develop Feb 5, 2024
2 checks passed
@vmidyllic vmidyllic deleted the fix/multi-query-hashes-order branch February 5, 2024 08:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants