Skip to content

Commit

Permalink
Fix cleric impetus spamming client log (#720)
Browse files Browse the repository at this point in the history
  • Loading branch information
SamsTheNerd authored Aug 21, 2024
2 parents 2759689 + 4b96530 commit 5bb1ed1
Showing 1 changed file with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,11 @@ public BlockEntityRedstoneImpetus(BlockPos pWorldPosition, BlockState pBlockStat

protected @Nullable
GameProfile getPlayerName() {
Player player = getStoredPlayer();
if (player != null) {
return player.getGameProfile();
if (this.level instanceof ServerLevel) {
Player player = getStoredPlayer();
if (player != null) {
return player.getGameProfile();
}
}

return this.storedPlayerProfile;
Expand Down

0 comments on commit 5bb1ed1

Please sign in to comment.