Skip to content

Fix VanishStatusChangeEvent NPE and document parameter inversion#6510

Merged
JRoy merged 1 commit intoEssentialsX:2.xfrom
JRoy:fix/6388-vanish-event-npe
Apr 12, 2026
Merged

Fix VanishStatusChangeEvent NPE and document parameter inversion#6510
JRoy merged 1 commit intoEssentialsX:2.xfrom
JRoy:fix/6388-vanish-event-npe

Conversation

@JRoy
Copy link
Copy Markdown
Member

@JRoy JRoy commented Apr 12, 2026

The affected/controller parameters are swapped in Commandvanish (#2604) but cannot be fixed without breaking the public API.

Fix BukkitListener to use getController() (the actual vanished player) instead of getAffected() (the sender, null for console), and add inversion warning javadoc matching the NickChangeEvent pattern.

Fixes #6388

The affected/controller parameters are swapped in Commandvanish
(EssentialsX#2604) but cannot be fixed without breaking the public API.

Fix BukkitListener to use getController() (the actual vanished player)
instead of getAffected() (the sender, null for console), and add
inversion warning javadoc matching the NickChangeEvent pattern.

Fixes EssentialsX#6388
Copy link
Copy Markdown
Member

@mdcfe mdcfe left a comment

Choose a reason for hiding this comment

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

Only possible suggestion would be adding a set of "get real affected / controller" methods, but those would be redundant

@JRoy JRoy added this pull request to the merge queue Apr 12, 2026
Merged via the queue into EssentialsX:2.x with commit b594358 Apr 12, 2026
1 check passed
@JRoy JRoy deleted the fix/6388-vanish-event-npe branch April 12, 2026 21:12
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.

Could not pass event VanishStatusChangeEvent to EssentialsDiscord ...

2 participants