helios icon indicating copy to clipboard operation
helios copied to clipboard

issues adding null values to document

Open ankitkhedekar opened this issue 7 years ago • 0 comments

When I try to update a document with one of its field as null, I get the following error stack trace:

TypeError: Cannot read property 'replace' of null
    at Object.escapeXML (C:\project\node_modules\helios\lib\utils.js:14:15)
    at solrDoc.toXML (C:\project\node_modules\helios\lib\document.js:179:23)
    at solrClient.addDoc (C:\project\node_modules\helios\lib\client.js:127:36)

It seems to be an issue because the escapeXML gets called on null values as well.

Can we skip this escaping step for null values or make the escapeXML function to handle null values differently?

ankitkhedekar avatar May 26 '17 09:05 ankitkhedekar