mirror of
https://github.com/Minestom/Minestom.git
synced 2024-11-08 03:40:27 +01:00
Add default impl for hasTag
This commit is contained in:
parent
2b5b11a483
commit
3e4a99a80c
@ -24,7 +24,9 @@ public interface TagReadable {
|
||||
* @param tag the tag to check
|
||||
* @return true if the tag is present, false otherwise
|
||||
*/
|
||||
boolean hasTag(@NotNull Tag<?> tag);
|
||||
default boolean hasTag(@NotNull Tag<?> tag) {
|
||||
return getTag(tag) != null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Converts an nbt compound to a tag reader.
|
||||
|
Loading…
Reference in New Issue
Block a user