Socket
Socket
Sign inDemoInstall

gaxios

Package Overview
Dependencies
Maintainers
1
Versions
78
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

gaxios - npm Package Compare versions

Comparing version 6.0.2 to 6.0.3

11

build/src/gaxios.js

@@ -326,3 +326,3 @@ "use strict";

*/
getResponseDataFromContentType(response) {
async getResponseDataFromContentType(response) {
let contentType = response.headers.get('Content-Type');

@@ -335,3 +335,10 @@ if (contentType === null) {

if (contentType.includes('application/json')) {
return response.json();
let data = await response.text();
try {
data = JSON.parse(data);
}
catch (_a) {
// continue
}
return data;
}

@@ -338,0 +345,0 @@ else if (contentType.includes('text/plain') ||

# Changelog
## [6.0.3](https://github.com/googleapis/gaxios/compare/v6.0.2...v6.0.3) (2023-07-24)
### Bug Fixes
* Handle invalid json when Content-Type=application/json ([#558](https://github.com/googleapis/gaxios/issues/558)) ([71602eb](https://github.com/googleapis/gaxios/commit/71602ebc2ab18d5af904b152723756f57fb13bce))
## [6.0.2](https://github.com/googleapis/gaxios/compare/v6.0.1...v6.0.2) (2023-07-20)

@@ -4,0 +11,0 @@

2

package.json
{
"name": "gaxios",
"version": "6.0.2",
"version": "6.0.3",
"description": "A simple common HTTP client specifically for Google APIs and services.",

@@ -5,0 +5,0 @@ "main": "build/src/index.js",

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