Skip to content

Commit

Permalink
Update MultiblockBlockEntity.java
Browse files Browse the repository at this point in the history
  • Loading branch information
Edivad99 committed Sep 22, 2023
1 parent b9e54cb commit ee605d6
Showing 1 changed file with 1 addition and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -236,13 +236,7 @@ public boolean isMaster() {
* @return an optional {@link Membership}
*/
public Optional<Membership<T>> getMembership() {
if (this.level.isClientSide()) {
// Some mods call this method client side, in order not to crash
// we return an Optional.empty() and print a warning.
// logger.warn("getMembership is server-side only.");
return Optional.empty();
}
return Optional.ofNullable(this.membership);
return this.level.isClientSide() ? Optional.empty() : Optional.ofNullable(this.membership);
}

public Optional<T> getMasterBlockEntity() {
Expand Down

0 comments on commit ee605d6

Please sign in to comment.