Skip to content
This repository has been archived by the owner on Jun 29, 2023. It is now read-only.

Unnecessary restriction on MassMigration commitments #683

Open
msieczko opened this issue Feb 14, 2022 · 0 comments · May be fixed by #684
Open

Unnecessary restriction on MassMigration commitments #683

msieczko opened this issue Feb 14, 2022 · 0 comments · May be fixed by #684

Comments

@msieczko
Copy link

The current implementation of claimTokens method blacklists a pubkeyID for given withdrawRoot to prevent claiming the same token amount twice.

require(
!Bitmap.isClaimed(withdrawal.state.pubkeyID, bitmap[withdrawRoot]),
"WithdrawManager: Token has been claimed"
);

As a result this introduces a restriction on the MassMigration transactions that can be put into a single commitment. Namely, there can be no two transactions from UserStates with the same pubkeyID in a single MassMigration commitment.

Instead we could blacklist a specific path in withdraw states tree to drop this unnecessary restriction.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant