ezobjects
Advanced tools
Comparing version 5.4.2 to 5.4.3
const docket = require(`docket-parser`); | ||
docket.title(`EZ Objects v5.4.2`); | ||
docket.title(`EZ Objects v5.4.3`); | ||
docket.linkClass(`text-success`); | ||
docket.parseFiles([`index.js`]); | ||
docket.generateDocs(`docs`); |
@@ -22,3 +22,3 @@ /** | ||
throw new TypeError(`${property.className}.${property.name}(): Null value passed to '${property.type}' setter that doesn't allow nulls.`); | ||
else if ( x !== null && property.ezobjectType.jsType == 'number' && typeof x !== 'number' ) | ||
else if ( x !== null && property.ezobjectType.jsType == 'number' && isNaN(x) ) | ||
throw new TypeError(`${property.className}.${property.name}(): Non-numeric value passed to '${property.type}' setter.`); | ||
@@ -67,3 +67,3 @@ else if ( x !== null && property.ezobjectType.jsType == 'string' && typeof x !== 'string' && typeof x !== 'number' ) | ||
throw new TypeError(`${property.className}.${property.name}(): Non-numeric value passed as element of Array[${property.arrayOf.type}] setter.`); | ||
else if ( property.ezobjectType.jsType == 'string' && x && x.some(y => typeof y !== 'string' && y !== null) ) | ||
else if ( property.ezobjectType.jsType == 'string' && x && x.some(y => typeof y !== `string` && y !== `number` && y !== null) ) | ||
throw new TypeError(`${property.className}.${property.name}(): Non-string value passed as element of Array[${property.arrayOf.type}] setter.`); | ||
@@ -91,2 +91,4 @@ else if ( property.ezobjectType.jsType == 'boolean' && x && x.some(y => typeof y !== 'boolean' && y !== null) ) | ||
arr = x.map(y => y === null ? null : (y ? true : false)); | ||
else if ( property.arrayOf.ezobjectType.jsType == `string` ) | ||
arr = x.map(y => y === null ? null : y.toString()); | ||
else | ||
@@ -93,0 +95,0 @@ arr = x.map(y => y === null ? null : y); |
{ | ||
"name": "ezobjects", | ||
"version": "5.4.2", | ||
"version": "5.4.3", | ||
"description": "Easy Auto-Generated Strictly-Typed JavaScript Class Objects", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -1,2 +0,2 @@ | ||
# EZ Objects v5.4.2 | ||
# EZ Objects v5.4.3 | ||
@@ -3,0 +3,0 @@ EZ Objects is a Node.js module (that can also be usefully browserify'd) that aims to save you lots of time |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
340028
1589