Socket
Socket
Sign inDemoInstall

@elastic/transport

Package Overview
Dependencies
Maintainers
53
Versions
37
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@elastic/transport - npm Package Compare versions

Comparing version 8.3.1 to 8.3.2

17

lib/connection/HttpConnection.js

@@ -299,2 +299,4 @@ "use strict";

const url = this.url;
let search = url.search;
let pathname = url.pathname;
const request = {

@@ -305,8 +307,3 @@ protocol: url.protocol,

: url.hostname,
hash: url.hash,
search: url.search,
pathname: url.pathname,
path: '',
href: url.href,
origin: url.origin,
// https://github.com/elastic/elasticsearch-js/issues/843

@@ -322,10 +319,10 @@ port: url.port !== '' ? url.port : undefined,

if (key === 'path') {
request.pathname = resolve(request.pathname, params[key]);
pathname = resolve(pathname, params[key]);
}
else if (key === 'querystring' && Boolean(params[key])) {
if (request.search === '') {
request.search = `?${params[key]}`;
if (search === '') {
search = `?${params[key]}`;
}
else {
request.search += `&${params[key]}`;
search += `&${params[key]}`;
}

@@ -341,3 +338,3 @@ }

}
request.path = request.pathname + request.search;
request.path = pathname + search;
return request;

@@ -344,0 +341,0 @@ }

@@ -168,2 +168,3 @@ "use strict";

}
// @ts-expect-error Assume header is not string[] for now.
const contentEncoding = ((_o = response.headers['content-encoding']) !== null && _o !== void 0 ? _o : '').toLowerCase();

@@ -170,0 +171,0 @@ const isCompressed = contentEncoding.includes('gzip') || contentEncoding.includes('deflate'); // eslint-disable-line

{
"name": "@elastic/transport",
"version": "8.3.1",
"version": "8.3.2",
"description": "Transport classes and utilities shared among Node.js Elastic client libraries",

@@ -65,3 +65,3 @@ "main": "index.js",

"tslib": "^2.4.0",
"undici": "^5.5.1"
"undici": "^5.22.1"
},

@@ -68,0 +68,0 @@ "tap": {

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc