xml-toolkit 1.0.58 → 1.0.59

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -77,7 +77,7 @@ const XMLMarshaller = class {
77
77
 
78
78
  }
79
79
 
80
- if (data [XSI_TYPE]) {
80
+ if (data && data [XSI_TYPE]) {
81
81
 
82
82
  let {targetNamespace} = this.xs.getSchemaByLocalName(data [XSI_TYPE])
83
83
 
@@ -109,7 +109,7 @@ const XMLMarshaller = class {
109
109
 
110
110
  const {attributes: {type}, children} = node
111
111
 
112
- if (data [XSI_TYPE]) {
112
+ if (data && data [XSI_TYPE]) {
113
113
  let d = {}; for (let k in data) d [k] = data [k]
114
114
  this.appendContent (this.schema.getType (data [XSI_TYPE]), d)
115
115
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "xml-toolkit",
3
- "version": "1.0.58",
3
+ "version": "1.0.59",
4
4
  "description": "XML parser, marshaller, SOAP adapter",
5
5
  "main": "index.js",
6
6
  "files": [