Skip to content

Commit b4e83a0

Browse files
committed
changes
1 parent e7c33ca commit b4e83a0

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

paper-api/src/main/java/org/bukkit/inventory/ItemTypeRecipeChoiceImpl.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,13 @@
1010
record ItemTypeRecipeChoiceImpl(RegistryKeySet<ItemType> itemTypes) implements RecipeChoice.ItemTypeChoice {
1111

1212
ItemTypeRecipeChoiceImpl {
13-
Preconditions.checkArgument(!itemTypes.isEmpty(), "RecipeChoice.ItemTypeChoice cannot be empty");
14-
Preconditions.checkArgument(!(itemTypes.contains(ItemTypeKeys.AIR)), "RecipeChoice.ItemTypeChoice cannot contain minecraft:air");
13+
Preconditions.checkArgument(!itemTypes.isEmpty(), "ItemTypeChoice cannot be empty");
14+
Preconditions.checkArgument(!(itemTypes.contains(ItemTypeKeys.AIR)), "ItemTypeChoice cannot contain minecraft:air");
1515
}
1616

1717
@Override
1818
public ItemStack getItemStack() {
19-
throw new UnsupportedOperationException("ItemTypeRecipeChoice does not support this");
19+
throw new UnsupportedOperationException("ItemTypeChoice does not support this");
2020
}
2121

2222
@Override
@@ -31,7 +31,7 @@ public boolean test(final ItemStack itemStack) {
3131

3232
@Override
3333
public RecipeChoice validate(final boolean allowEmptyRecipes) {
34-
Preconditions.checkArgument(!(this.itemTypes.contains(ItemTypeKeys.AIR)), "RecipeChoice.ItemTypeChoice cannot contain minecraft:air");
34+
Preconditions.checkArgument(!(this.itemTypes.contains(ItemTypeKeys.AIR)), "ItemTypeChoice cannot contain minecraft:air");
3535
return this;
3636
}
3737
}

paper-api/src/main/java/org/bukkit/inventory/RecipeChoice.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -310,7 +310,7 @@ public RecipeChoice validate(final boolean allowEmptyRecipes) {
310310
*/
311311
@ApiStatus.Experimental
312312
@ApiStatus.NonExtendable
313-
interface ItemTypeChoice extends RecipeChoice {
313+
sealed interface ItemTypeChoice extends RecipeChoice permits ItemTypeRecipeChoiceImpl {
314314

315315
/**
316316
* Gets the set of item types that this choice will match.

0 commit comments

Comments
 (0)