Skip to content
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

Add direction null check #3647

Merged
merged 1 commit into from
Mar 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@ to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

- Added Hungarian translation.

### Fixed

- Fixed an error that occurred when targeting the crafter with Jade installed

## [1.13.0-beta.3] - 2024-03-05

### Fixed
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
import com.refinedmods.refinedstorage.screen.CrafterBlockEntitySynchronizationClientListener;

import javax.annotation.Nonnull;
import javax.annotation.Nullable;

import net.minecraft.core.BlockPos;
import net.minecraft.core.Direction;
Expand Down Expand Up @@ -44,8 +45,8 @@ public CrafterNetworkNode createNode(Level level, BlockPos pos) {
return new CrafterNetworkNode(level, pos);
}

public IItemHandler getPatterns(Direction direction) {
if (!direction.equals(this.getNode().getDirection())) {
public IItemHandler getPatterns(@Nullable Direction direction) {
if (direction != null && !direction.equals(this.getNode().getDirection())) {
return getNode().getPatternInventory();
}
return null;
Expand Down
Loading