Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

xhr

Package Overview
Dependencies
Maintainers
1
Versions
60
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

xhr - npm Package Compare versions

Comparing version 1.8.0 to 1.9.0

12

index.js

@@ -92,5 +92,11 @@ var window = require("global/window")

var status = xhr.statusCode = xhr.status
var body = xhr.body = xhr.response ||
xhr.responseText || xhr.responseXML
// Chrome with requestType=blob throws errors arround when even testing access to responseText
var body = null
if (xhr.response) {
body = xhr.body = xhr.response
} else if (xhr.responseType === 'text' || xhr.responseType === '') {
body = xhr.body = xhr.responseText || xhr.responseXML
}
if (status === 1223) {

@@ -101,3 +107,3 @@ status = 204

if (status === 0 || (status >= 400 && status < 600)) {
var message = xhr.responseText ||
var message = (typeof body === "string" ? body : false) ||
messages[String(xhr.status).charAt(0)]

@@ -104,0 +110,0 @@ error = new Error(message)

{
"name": "xhr",
"version": "1.8.0",
"version": "1.9.0",
"description": "small xhr abstraction",

@@ -5,0 +5,0 @@ "keywords": [

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