Skip to content

fix: NettyChannelInjector.getPlayer() overwrites TemporaryPlayer with null#3629

Open
NekoEpisode wants to merge 1 commit into
dmulloy2:masterfrom
NekoEpisode:fix-injector-getplayer
Open

fix: NettyChannelInjector.getPlayer() overwrites TemporaryPlayer with null#3629
NekoEpisode wants to merge 1 commit into
dmulloy2:masterfrom
NekoEpisode:fix-injector-getplayer

Conversation

@NekoEpisode
Copy link
Copy Markdown

Bukkit.getPlayerExact() returns null during login phase. Assigning its return value directly to this.player destroys the TemporaryPlayer instance, causing subsequent getPlayer() calls to return null. Use a local variable to only replace the player on success

… null

Bukkit.getPlayerExact() returns null during login phase. Assigning its
return value directly to this.player destroys the TemporaryPlayer instance,
causing subsequent getPlayer() calls to return null. Use a local variable
to only replace the player on success.
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.

1 participant