Skip to content

Commit

Permalink
Reset previous settings when opening the ItemCreator to edit a new item
Browse files Browse the repository at this point in the history
  • Loading branch information
WolfyScript committed Mar 15, 2024
1 parent bf3fa5d commit 9fbf37e
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -133,13 +133,15 @@ public boolean isBukkitIdentifier() {
}

public void editCustomItem(CustomItem customItem) {
editorWasPreviouslyCancelled(false);
setItem(customItem);
setNamespacedKey(customItem.getNamespacedKey());
setSaved(true);
}

public void createCustomItem(StackReference reference) {
this.original = reference;
editorWasPreviouslyCancelled(false);
setItem(new CustomItem(reference));
setNamespacedKey(null);
setSaved(false);
Expand Down

0 comments on commit 9fbf37e

Please sign in to comment.