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

fix https://github.com/sherlock-audit/2023-03-Y2K-judging/issues/72 #127

Merged
merged 3 commits into from
May 10, 2023

Conversation

3xHarry
Copy link
Contributor

@3xHarry 3xHarry commented Apr 7, 2023

  • don't delete Queue item from rollover queue but rather set assets to 0
  • add getters

// check if user has already queued up a rollover
if (ownerToRollOverQueueIndex[_receiver] != 0) {
// if so, update the queue
if (isEnlistedInRolloverQueue(_receiver)) {
Copy link

Choose a reason for hiding this comment

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

Using this will create a new QueueItem for delisted user instead of repopulating (since isEnlistedInRolloverQueue will return false if assets == 0), making it impossible to ever clean them up after

Copy link

@IAm0x52 IAm0x52 left a comment

Choose a reason for hiding this comment

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

Needs additional changes. Using isEnlistedInRolloverQueue causes duplicate entries that can't be removed

@3xHarry
Copy link
Contributor Author

3xHarry commented May 6, 2023

hey @IAm0x52 i literally run into this issue while testing on test env! THX for catching this!

@3xHarry 3xHarry merged commit d6fab17 into sherlock-fix-3 May 10, 2023
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.

2 participants