Skip to content

Commit

Permalink
Fix hind pledge nullability
Browse files Browse the repository at this point in the history
  • Loading branch information
dhyces committed Apr 6, 2024
1 parent 6d4bbcc commit c7e0cbc
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,12 @@ public UUID getHindUuid() {
public void setHindUuid(@Nullable UUID uuid) {
if (!getWorld().isClient) {
PledgeState pledgeState = ((AttachmentTarget)getWorld()).getAttachedOrCreate(ModAttachmentTypes.PLEDGE_STATE);
pledgeState.addPledge(getUuid(), uuid);
if (uuid == null) {
pledgeState.removePledge((PlayerEntity)(Object) this);
} else {
pledgeState.addPledge(getUuid(), uuid);
}

}
}

Expand Down

0 comments on commit c7e0cbc

Please sign in to comment.