Type system fixes

This commit is contained in:
barsdeveloper
2022-04-11 23:35:28 +02:00
parent 4b045b4c70
commit f71edf1a3c
7 changed files with 55 additions and 57 deletions

View File

@@ -25,8 +25,7 @@ export default class ObjectSerializer extends ISerializer {
read(value) {
const parseResult = ISerializer.grammar.Object.parse(value)
if (!parseResult.status) {
console.error("Error when trying to parse the object.")
return parseResult
throw new Error("Error when trying to parse the object.")
}
return parseResult.value
}