@victorhalla/n8n-nodes-wwebjsapi 1.1.0 → 1.1.1

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.
@@ -1 +1 @@
1
- {"version":3,"file":"WWebjsApi.node.d.ts","sourceRoot":"","sources":["../../../nodes/WWebjsApi/WWebjsApi.node.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EACL,iBAAiB,EAEjB,qBAAqB,EACrB,kBAAkB,EAClB,qBAAqB,EACrB,SAAS,EACT,oBAAoB,EAErB,MAAM,cAAc,CAAC;AAEtB,qBAAa,SAAU,YAAW,SAAS;IACzC,WAAW,EAAE,oBAAoB,CA40K/B;IAEF,OAAO;;8BAEqB,qBAAqB,GAAG,OAAO,CAAC,qBAAqB,CAAC;;MAuChF;IAEI,OAAO,CAAC,IAAI,EAAE,iBAAiB,GAAG,OAAO,CAAC,kBAAkB,EAAE,EAAE,CAAC;CAqhGxE"}
1
+ {"version":3,"file":"WWebjsApi.node.d.ts","sourceRoot":"","sources":["../../../nodes/WWebjsApi/WWebjsApi.node.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EACL,iBAAiB,EAEjB,qBAAqB,EACrB,kBAAkB,EAClB,qBAAqB,EACrB,SAAS,EACT,oBAAoB,EAErB,MAAM,cAAc,CAAC;AAEtB,qBAAa,SAAU,YAAW,SAAS;IACzC,WAAW,EAAE,oBAAoB,CA40K/B;IAEF,OAAO;;8BAEqB,qBAAqB,GAAG,OAAO,CAAC,qBAAqB,CAAC;;MAuChF;IAEI,OAAO,CAAC,IAAI,EAAE,iBAAiB,GAAG,OAAO,CAAC,kBAAkB,EAAE,EAAE,CAAC;CAyhGxE"}
@@ -8092,9 +8092,11 @@ class WWebjsApi {
8092
8092
  returnFullResponse: false,
8093
8093
  json: false,
8094
8094
  };
8095
- const _binaryOptions = { ...options, encoding: null };
8095
+ const _binaryOptions = { ...options, encoding: 'binary' };
8096
8096
  const _rawResp = await this.helpers.httpRequest(_binaryOptions);
8097
- const _buffer = Buffer.isBuffer(_rawResp) ? _rawResp : Buffer.from(_rawResp);
8097
+ const _buffer = Buffer.isBuffer(_rawResp)
8098
+ ? _rawResp
8099
+ : Buffer.from(_rawResp, 'binary');
8098
8100
  const _binaryData = await this.helpers.prepareBinaryData(_buffer, 'getSessionQrImage.png', 'image/png');
8099
8101
  responseData = { binary: _binaryData, mimeType: 'image/png' };
8100
8102
  break;
@@ -8180,9 +8182,11 @@ class WWebjsApi {
8180
8182
  returnFullResponse: false,
8181
8183
  json: false,
8182
8184
  };
8183
- const _binaryOptions = { ...options, encoding: null };
8185
+ const _binaryOptions = { ...options, encoding: 'binary' };
8184
8186
  const _rawResp = await this.helpers.httpRequest(_binaryOptions);
8185
- const _buffer = Buffer.isBuffer(_rawResp) ? _rawResp : Buffer.from(_rawResp);
8187
+ const _buffer = Buffer.isBuffer(_rawResp)
8188
+ ? _rawResp
8189
+ : Buffer.from(_rawResp, 'binary');
8186
8190
  const _binaryData = await this.helpers.prepareBinaryData(_buffer, 'getSessionGetPageScreenshot.png', 'image/png');
8187
8191
  responseData = { binary: _binaryData, mimeType: 'image/png' };
8188
8192
  break;