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

divhide

Package Overview
Dependencies
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

divhide - npm Package Compare versions

Comparing version 1.0.4 to 1.0.5

divhide-1.0.5.tgz

2

bower.json

@@ -6,3 +6,3 @@ {

"license": "MIT",
"version": "1.0.4",
"version": "1.0.5",

@@ -9,0 +9,0 @@ "authors": [

{
"name": "divhide",
"description": "Divhide javascript core components for NodeJs, Browser, Titanium, ... and everything that runs javascript.",
"version": "1.0.4",
"version": "1.0.5",
"author": {

@@ -6,0 +6,0 @@ "name": "Oscar Brito <aetheon@gmail.com>",

@@ -539,2 +539,6 @@ # [![Divhide](http://blog.divhide.com/assets/images/divhide_128px.png)](http://divhide.com/) divhide-core

`.boolean()`
<br />
Set the expected type as a boolean
`.object(value)`

@@ -541,0 +545,0 @@ <br />

@@ -90,3 +90,3 @@ 'use strict';

function : function(val, obj){
function : function(){
this.schema = function(){};

@@ -97,3 +97,3 @@ this.required = true;

number : function(val){
number : function(){
this.schema = 0;

@@ -104,2 +104,8 @@ this.required = true;

boolean : function(){
this.schema = Boolean(true);
this.required = true;
this.any = false;
},
default : function(val, defaultValue){

@@ -106,0 +112,0 @@ this.default = defaultValue;

@@ -19,2 +19,6 @@

`.boolean()`
<br />
Set the expected type as a boolean
`.object(value)`

@@ -21,0 +25,0 @@ <br />

@@ -83,2 +83,18 @@ "use strict";

boolean: function(value){
if(!Type.isBoolean(value)){
return;
}
// no default value and its required!
value = new SchemaDefinition({
schema: Boolean(value),
required: true
});
return value;
},
function: function(value){

@@ -98,3 +114,3 @@

}
},

@@ -130,3 +146,3 @@ };

Defaults.string(schema) || Defaults.number(schema) ||
Defaults.function(schema);
Defaults.boolean(schema) || Defaults.function(schema);

@@ -133,0 +149,0 @@ if(!result){

@@ -30,4 +30,8 @@ 'use strict';

if(t == "object" && obj instanceof Array)
if(t == "object" && obj instanceof Array){
return "array";
}
else if(t == "object" && typeof(obj) == "boolean"){
return "boolean";
}

@@ -34,0 +38,0 @@ return t;

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

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

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