From 0a661a855e8ab42d9245fdf633b34276ec40b881 Mon Sep 17 00:00:00 2001 From: Julien Fontanet Date: Thu, 25 Apr 2024 15:56:23 +0200 Subject: [PATCH] fix: boolean is true if content is the string '1' XML does not contain numbers --- src/lib/xmlrpc-parser.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/xmlrpc-parser.js b/src/lib/xmlrpc-parser.js index 0adeda5..0f928e3 100644 --- a/src/lib/xmlrpc-parser.js +++ b/src/lib/xmlrpc-parser.js @@ -144,7 +144,7 @@ XmlRpcParser.prototype.getHandler = function getHandler() { // Parse a boolean into the JS equivalent. case 'boolean': instance.isImplicitString = false; - instance.valueStack.push(cdata === 'true' || cdata === 1); + instance.valueStack.push(cdata === 'true' || cdata === '1'); break; // Parse a date from its ISO 8601 representation. case 'dateTime.iso8601':