-
Notifications
You must be signed in to change notification settings - Fork 71
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
refactor: VerifyMembership and VerifyNonMembership api #391
refactor: VerifyMembership and VerifyNonMembership api #391
Conversation
running into a bit of import issues as this fn is depended on by cosmos/iavl, cosmos/cosmos-sdk, and cosmos/ibc-go. Might be good to see what the update flow is before merging |
go/ics23.go
Outdated
return ep | ||
} | ||
} | ||
if !isLeft(spec, np.Left, key) || !isRight(spec, np.Right, key) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe this check should be within NonExistenceProof.Verify
?
…thub.com:cosmos/ics23 into colin/update-verify-membership-and-nonmembership
switch p := proof.Proof.(type) { | ||
case *CommitmentProof_Exist: | ||
ep := p.Exist | ||
if bytes.Equal(ep.Key, key) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
checked in ep.Verify
switch p := proof.Proof.(type) { | ||
case *CommitmentProof_Nonexist: | ||
np := p.Nonexist | ||
if isLeft(spec, np.Left, key) && isRight(spec, np.Right, key) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
checked in np.Verify
…rify-membership-and-nonmembership
ref: #389