From e49c873f4cb448f8964229491e91909a85c46fab Mon Sep 17 00:00:00 2001 From: Marcin Licznerski Date: Wed, 30 Oct 2024 21:38:59 +0100 Subject: [PATCH] Fix removal of struct header in Rfc3986 --- package.json | 2 +- src/struct/rfc3986.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index b940b10..bde550b 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@adscore/nodejs-common", - "version": "1.0.6", + "version": "1.0.7", "description": "NodeJS client library for Adscore", "scripts": { "prepare-package": "rm -r -f ./dist && npm run generate-barrels && tsc && npm run copy-files", diff --git a/src/struct/rfc3986.ts b/src/struct/rfc3986.ts index 6215f72..1e332e2 100644 --- a/src/struct/rfc3986.ts +++ b/src/struct/rfc3986.ts @@ -23,7 +23,7 @@ export class Rfc3986 extends AbstractStruct { * @return array */ public unpack(data: Buffer): string { - const searchParams = new URLSearchParams(data.toString()); + const searchParams = new URLSearchParams(super.unpack(data).toString()); const res = Array.from(searchParams.entries()).reduce((curr, prev) => { curr[prev[0]] = prev[1];