Fix crash with some more types of empty paths

This commit is contained in:
embeddedt 2023-04-16 14:38:11 -04:00
parent 0af09b7e27
commit 1602d3352f
No known key found for this signature in database
GPG Key ID: A69433EC199B5613

View File

@ -86,6 +86,8 @@ public abstract class ModFileResourcePackMixin {
return false;
}
String str = path.toString();
if(str.length() == 0)
return false;
for(int i = 0; i < str.length(); i++) {
if(!ResourceLocation.validPathChar(str.charAt(i))) {
return false;