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

dresscode-bricks

Package Overview
Dependencies
Maintainers
1
Versions
26
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

dresscode-bricks - npm Package Compare versions

Comparing version 0.2.2 to 0.2.3

12

lib/Bricks/Remote.js

@@ -45,12 +45,10 @@ Bricks.Remote = Bricks.Component.inherit({

xhr.onreadystatechange = function() {
if (xhr.readyState == 4) {
if (xhr.readyState === 4) {
xhr.onreadystatechange = null;
if (xhr.status == 200) {
callback.call(ctx, that._parseResponse(xhr), xhr);
} else {
callback.call(ctx, null, xhr);
if (callback) {
callback.call(ctx, xhr.status === 200 ? that._parseResponse(xhr) : null, xhr);
}
}
};
if (method == 'POST' || method == 'PUT') {
if (method === 'POST' || method === 'PUT') {
xhr.setRequestHeader('Content-Type', this.contentType);

@@ -74,3 +72,3 @@ xhr.send(this._encodePostParams(postParams));

var contentType = xhr.getResponseHeader('Content-Type') || '';
if (contentType.indexOf('application/json') == 0) {
if (contentType.indexOf('application/json') === 0) {
return Bricks.JSON.parse(xhr.responseText, function(k, v) {

@@ -77,0 +75,0 @@ return typeof v == 'string' && /^\d\d\d\d-\d\d-\d\dT\d\d:\d\d:\d\d.\d\d\dZ$/.test(v) ? new Date(v) : v;

{
"name": "dresscode-bricks",
"version": "0.2.2",
"version": "0.2.3",
"author": {

@@ -5,0 +5,0 @@ "name": "Kolyaj",

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