Skip to content

Commit

Permalink
Fix: Check for null player before sorting inventory
Browse files Browse the repository at this point in the history
  • Loading branch information
anviaan committed Oct 12, 2024
1 parent af7ef3f commit 70a7af1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ yarn_mappings=1.21+build.9
loader_version=0.15.11

# Mod Properties
mod_version=2.5
mod_version=2.6
maven_group=net.anvian.inventorytweaks
archives_base_name=InventoryTweaks

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,7 @@ private void onMouseClicked(double mouseX, double mouseY, int button, CallbackIn

@Unique
private void inventoryTweakSortingKeyPressed() {
if (MinecraftClient.getInstance().player == null) {
return;
}
if (MinecraftClient.getInstance().player == null) return;

ScreenHandler screenHandler = MinecraftClient.getInstance().player.currentScreenHandler;
Screen screen = MinecraftClient.getInstance().currentScreen;
Expand Down

0 comments on commit 70a7af1

Please sign in to comment.