From 6efc5e0c43a388fef3c5f4d40ffd1d2805d1e4e7 Mon Sep 17 00:00:00 2001 From: James Stenhouse Date: Sat, 4 Jul 2020 19:05:59 +1000 Subject: [PATCH] fix spaces in returned ObjectName --- lib/messages/search_entry.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/messages/search_entry.js b/lib/messages/search_entry.js index b6ba798..5bc6bfe 100644 --- a/lib/messages/search_entry.js +++ b/lib/messages/search_entry.js @@ -171,7 +171,8 @@ SearchEntry.prototype._parse = function (ber) { SearchEntry.prototype._toBer = function (ber) { assert.ok(ber) - ber.writeString(this.objectName.toString()) + var formattedObjectName = this.objectName.format({ skipSpace: true }) + ber.writeString(formattedObjectName) ber.startSequence() this.attributes.forEach(function (a) { // This may or may not be an attribute