New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@aws-amplify/core

Package Overview
Dependencies
Maintainers
10
Versions
2123
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@aws-amplify/core - npm Package Compare versions

Comparing version 1.0.26-unstable.0 to 1.0.26-unstable.1

11

CHANGELOG.md

@@ -6,2 +6,13 @@ # Change Log

<a name="1.0.26-unstable.1"></a>
## [1.0.26-unstable.1](https://github.com/aws/aws-amplify/compare/@aws-amplify/core@1.0.26-unstable.0...@aws-amplify/core@1.0.26-unstable.1) (2019-04-17)
### Bug Fixes
* **@aws-amplify/core:** directly return if input is null for function transferKeyToUpperCase/transferKeyToLowerCase ([1600cfb](https://github.com/aws/aws-amplify/commit/1600cfb))
<a name="1.0.26-unstable.0"></a>

@@ -8,0 +19,0 @@ ## [1.0.26-unstable.0](https://github.com/aws/aws-amplify/compare/@aws-amplify/core@1.0.25...@aws-amplify/core@1.0.26-unstable.0) (2019-04-12)

@@ -30,2 +30,8 @@ export default class JS {

static transferKeyToUpperCase(obj: any, whiteListForItself?: any[], whiteListForChildren?: any[]): any;
/**
* Return true if the object is a strict object
* which means it's not Array, Function, Number, String, Boolean or Null
* @param obj the Object
*/
static isStrictObject(obj: any): boolean;
}

17

lib/JS.js

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

if (whiteListForChildren === void 0) { whiteListForChildren = []; }
if (typeof obj !== 'object' || Array.isArray(obj))
if (!JS.isStrictObject(obj))
return obj;

@@ -183,3 +183,3 @@ var ret = {};

if (whiteListForChildren === void 0) { whiteListForChildren = []; }
if (typeof obj !== 'object' || Array.isArray(obj))
if (!JS.isStrictObject(obj))
return obj;

@@ -199,2 +199,15 @@ var ret = {};

};
/**
* Return true if the object is a strict object
* which means it's not Array, Function, Number, String, Boolean or Null
* @param obj the Object
*/
JS.isStrictObject = function (obj) {
return ((obj instanceof Object) &&
!(obj instanceof Array) &&
!(obj instanceof Function) &&
!(obj instanceof Number) &&
!(obj instanceof String) &&
!(obj instanceof Boolean));
};
return JS;

@@ -201,0 +214,0 @@ }());

2

package.json
{
"name": "@aws-amplify/core",
"version": "1.0.26-unstable.0",
"version": "1.0.26-unstable.1",
"description": "Core category of aws-amplify",

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

@@ -171,4 +171,3 @@ /*

static transferKeyToLowerCase(obj, whiteListForItself=[], whiteListForChildren=[]) {
if (typeof obj !== 'object' || Array.isArray(obj)) return obj;
if (!JS.isStrictObject(obj)) return obj;
const ret = {};

@@ -202,4 +201,3 @@

static transferKeyToUpperCase(obj, whiteListForItself=[], whiteListForChildren=[]) {
if (typeof obj !== 'object' || Array.isArray(obj)) return obj;
if (!JS.isStrictObject(obj)) return obj;
const ret = {};

@@ -225,2 +223,17 @@

}
/**
* Return true if the object is a strict object
* which means it's not Array, Function, Number, String, Boolean or Null
* @param obj the Object
*/
static isStrictObject(obj) {
return ((obj instanceof Object) &&
!(obj instanceof Array) &&
!(obj instanceof Function) &&
!(obj instanceof Number) &&
!(obj instanceof String) &&
!(obj instanceof Boolean)
);
}
}

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

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