mirror of
https://codeberg.org/keyoxide/doipjs.git
synced 2024-12-23 06:59:29 -07:00
Handle erroneous input better
This commit is contained in:
parent
51506b4a93
commit
05d6986349
1 changed files with 3 additions and 1 deletions
|
@ -32,7 +32,9 @@ const runOnJson = (res, proofData, checkPath, checkClaim, checkRelation) => {
|
||||||
return res
|
return res
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!(checkPath[0] in proofData)) {
|
try {
|
||||||
|
checkPath[0] in proofData
|
||||||
|
} catch(e) {
|
||||||
res.errors.push('err_data_structure_incorrect')
|
res.errors.push('err_data_structure_incorrect')
|
||||||
return res
|
return res
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue