Skip to content

fix(queue): don't go to next node if it has been removed #687

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

Merged
merged 1 commit into from
Jan 10, 2023

Conversation

mrbjarksen
Copy link
Contributor

If an event handler should be removed (by way of once = true or the handler returning true), the event queue erroneously skips handling the next node and jumps two nodes ahead. If this is the last event in the queue, this also results in an error (attempt to index a nil value).

Copy link
Contributor

@cseickel cseickel left a comment

Choose a reason for hiding this comment

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

Looks good, thanks!

@cseickel
Copy link
Contributor

That must have been a difficult bug to track down which led you to this fix... Sorry about that!

@cseickel cseickel merged commit d4dc784 into nvim-neo-tree:main Jan 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