Possible parser status effect fix

This commit is contained in:
Anuken
2023-05-08 09:50:33 -04:00
parent 72c67f6c9b
commit a4972886a3
2 changed files with 3 additions and 2 deletions

View File

@@ -781,13 +781,14 @@ public class ContentParser{
json = json.replace("#", "\\#");
}
currentMod = mod;
JsonValue value = parser.fromJson(null, Jval.read(json).toString(Jformat.plain));
if(!parsers.containsKey(type)){
throw new SerializationException("No parsers for content type '" + type + "'");
}
currentMod = mod;
boolean located = locate(type, name) != null;
Content c = parsers.get(type).parse(mod.name, name, value);
c.minfo.sourceFile = file;