ismx-nexo-node-app 0.4.178 → 0.4.179

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.
@@ -53,7 +53,7 @@ class RepositoryRest extends Repository_1.default {
53
53
  return call.then((res) => __awaiter(this, void 0, void 0, function* () {
54
54
  var _a, _b, _c, _d, _e;
55
55
  let headers = {};
56
- res.headers.forEach((value, key) => headers[key.toLowerCase()] = value);
56
+ Object.entries(res.headers).forEach(([key, value]) => headers[key.toLowerCase()] = value);
57
57
  let content = yield res.text();
58
58
  (_b = (_a = this.options).onRawResponse) === null || _b === void 0 ? void 0 : _b.call(_a, request, content);
59
59
  if ((_c = headers['content-type']) === null || _c === void 0 ? void 0 : _c.startsWith('application/json'))
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ismx-nexo-node-app",
3
- "version": "0.4.178",
3
+ "version": "0.4.179",
4
4
  "description": "",
5
5
  "scripts": {
6
6
  "build": "rm -rf ./dist && npx tsc",
@@ -66,7 +66,8 @@ export default class RepositoryRest<Body=any,Res=any> extends Repository
66
66
  // Añade información adicional a la respuesta y devuelve el resultado (o el error en su caso).
67
67
  // @ts-ignore
68
68
  return call.then(async (res: Response) => {
69
- let headers: any = {}; res.headers.forEach((value, key) => headers[key.toLowerCase()] = value);
69
+ let headers: any = {};
70
+ Object.entries(res.headers).forEach(([key, value]) => headers[key.toLowerCase()] = value);
70
71
  let content: string | E = await res.text();
71
72
  this.options.onRawResponse?.(request, content);
72
73