diff --git a/fabric-convention-tags-v2/src/client/java/net/fabricmc/fabric/impl/tag/convention/client/ConventionLogWarningsClient.java b/fabric-convention-tags-v2/src/client/java/net/fabricmc/fabric/impl/tag/convention/client/ConventionLogWarningsClient.java index 6e23ab788b..92d594e3fd 100644 --- a/fabric-convention-tags-v2/src/client/java/net/fabricmc/fabric/impl/tag/convention/client/ConventionLogWarningsClient.java +++ b/fabric-convention-tags-v2/src/client/java/net/fabricmc/fabric/impl/tag/convention/client/ConventionLogWarningsClient.java @@ -22,6 +22,7 @@ import java.util.List; import it.unimi.dsi.fastutil.objects.ObjectArrayList; +import net.minecraft.util.Identifier; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -56,7 +57,7 @@ private static void setupUntranslatedItemTagWarning() { List> untranslatedItemTags = new ObjectArrayList<>(); itemRegistry.streamTags().forEach(itemTagKey -> { // We do not translate vanilla's tags at this moment. - if (itemTagKey.id().getNamespace().equals("minecraft")) { + if (itemTagKey.id().getNamespace().equals(Identifier.DEFAULT_NAMESPACE)) { return; } diff --git a/fabric-convention-tags-v2/src/main/java/net/fabricmc/fabric/api/tag/convention/v2/TagUtil.java b/fabric-convention-tags-v2/src/main/java/net/fabricmc/fabric/api/tag/convention/v2/TagUtil.java index 27c7650968..2492a8ecda 100644 --- a/fabric-convention-tags-v2/src/main/java/net/fabricmc/fabric/api/tag/convention/v2/TagUtil.java +++ b/fabric-convention-tags-v2/src/main/java/net/fabricmc/fabric/api/tag/convention/v2/TagUtil.java @@ -94,7 +94,7 @@ public static String getTagTranslationKey(TagKey tagKey) { Identifier registryIdentifier = tagKey.registry().getValue(); Identifier tagIdentifier = tagKey.id(); - if (registryIdentifier.getNamespace().equals("minecraft")) { + if (!registryIdentifier.getNamespace().equals(Identifier.DEFAULT_NAMESPACE)) { stringBuilder.append(registryIdentifier.getNamespace()) .append("."); } diff --git a/fabric-convention-tags-v2/src/main/java/net/fabricmc/fabric/impl/tag/convention/ConventionLogWarnings.java b/fabric-convention-tags-v2/src/main/java/net/fabricmc/fabric/impl/tag/convention/ConventionLogWarnings.java index 851d26518d..d2708eadcd 100644 --- a/fabric-convention-tags-v2/src/main/java/net/fabricmc/fabric/impl/tag/convention/ConventionLogWarnings.java +++ b/fabric-convention-tags-v2/src/main/java/net/fabricmc/fabric/impl/tag/convention/ConventionLogWarnings.java @@ -22,6 +22,7 @@ import java.util.List; import it.unimi.dsi.fastutil.objects.ObjectArrayList; +import net.minecraft.util.Identifier; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -54,7 +55,7 @@ private static void setupLegacyTagWarning() { // We only care about vanilla registries dynamicRegistries.streamAllRegistries().forEach(registryEntry -> { - if (registryEntry.key().getValue().getNamespace().equals("minecraft")) { + if (registryEntry.key().getValue().getNamespace().equals(Identifier.DEFAULT_NAMESPACE)) { registryEntry.value().streamTags().forEach(tagKey -> { // Grab tags under 'c' namespace if (tagKey.id().getNamespace().equals("c")) {