You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Uncaught exception: TypeError: Object.keys called on non-object, stack:
at Function.keys (native)
at keys (/root/nef/node_modules/amanda/releases/latest/amanda.js:334:17)
at Object.additionalProperties (/root/nef/node_modules/amanda/releases/latest/amanda.js:472:22)
at Validation.validateProperty.iterator (/root/nef/node_modules/amanda/releases/latest/amanda.js:1821:26)
at Array.addToQueue [as 0] (/root/nef/node_modules/amanda/releases/latest/amanda.js:86:16)
at asyncEach (/root/nef/node_modules/amanda/releases/latest/amanda.js:111:20)
at each (/root/nef/node_modules/amanda/releases/latest/amanda.js:118:22)
at Validation.validateProperty (/root/nef/node_modules/amanda/releases/latest/amanda.js:1840:10)
at Validation.validateSchema (/root/nef/node_modules/amanda/releases/latest/amanda.js:1856:15)
at Validation.validateItems (/root/nef/node_modules/amanda/releases/latest/amanda.js:1668:19)
apparently the data are not valid, as data are plain string and according to schema object is expected nevertheless amanda should report error properly and it shouldn't throw uncaught exception. The problem is in additionalPropertiesAttribute(). Before the method tries to get object properties by keys(propertyValue) it should check if the value which it is operating on is indeed an object and if not it should bail out from the function. Something like this:
/**
* AdditionalProperties
*/
var additionalPropertiesAttribute = function additionalProperties(property, propertyValue, attributeValue, propertyAttributes, callback) {
var self = this;
/**
* {
* additionalProperties: true,
* ...
* }
*/
if (attributeValue === true) {
return callback();
}
if (!isObject(propertyValue)) {
return callback();
}
// Filter the forbidden properties
var propertyKeys = keys(propertyValue);
...
The text was updated successfully, but these errors were encountered:
Following exception stack is printed:
when validating following data:
according to following scheme:
apparently the data are not valid, as data are plain string and according to schema object is expected nevertheless amanda should report error properly and it shouldn't throw uncaught exception. The problem is in additionalPropertiesAttribute(). Before the method tries to get object properties by keys(propertyValue) it should check if the value which it is operating on is indeed an object and if not it should bail out from the function. Something like this:
The text was updated successfully, but these errors were encountered: