We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Describe the bug After group imported, members return string[] indexOf function always return -1
To Reproduce Steps to reproduce the behavior:
const group_origin = new Group([1n, 2n, 3n, 4n, 5n]) const exported = group_origin.export() console.log('group test', group_origin.members) console.log(group_origin.indexOf(3n)) console.log(group_origin.indexOf('3')) console.log(group_origin.indexOf(BigInt('3'))) console.log(group_origin.members.indexOf(3n)) console.log(group_origin.members.indexOf(BigInt('3')))
const group = Group.import(exported) console.log('group imported', group.members) console.log(group.indexOf(3n)) console.log(group.indexOf('3')) console.log(group.indexOf(BigInt('3'))) console.log(group.members.indexOf(3n)) console.log(group.members.indexOf(BigInt('3')))
const converted = group.members.map(id => id.toString()) console.log('members bigint[] to string[]') console.log(converted.indexOf('3'))
Expected behavior imported group.indexOf return correct position
Screenshots
The text was updated successfully, but these errors were encountered:
import
Thanks @tochy-open 🙏🏽 WIP
Re: privacy-scaling-explorations/zk-kit#313
Sorry, something went wrong.
fix(group): update lean-imt dependency
869ee8b
re #847
fix(group): update lean-imt dependency (#850)
21c2739
cedoor
Successfully merging a pull request may close this issue.
Describe the bug
After group imported, members return string[]
indexOf function always return -1
To Reproduce
Steps to reproduce the behavior:
const group_origin = new Group([1n, 2n, 3n, 4n, 5n])
const exported = group_origin.export()
console.log('group test', group_origin.members)
console.log(group_origin.indexOf(3n))
console.log(group_origin.indexOf('3'))
console.log(group_origin.indexOf(BigInt('3')))
console.log(group_origin.members.indexOf(3n))
console.log(group_origin.members.indexOf(BigInt('3')))
const group = Group.import(exported)
console.log('group imported', group.members)
console.log(group.indexOf(3n))
console.log(group.indexOf('3'))
console.log(group.indexOf(BigInt('3')))
console.log(group.members.indexOf(3n))
console.log(group.members.indexOf(BigInt('3')))
const converted = group.members.map(id => id.toString())
console.log('members bigint[] to string[]')
console.log(converted.indexOf('3'))
Expected behavior
imported group.indexOf return correct position
Screenshots
The text was updated successfully, but these errors were encountered: