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

checkv

Package Overview
Dependencies
Maintainers
1
Versions
19
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

checkv - npm Package Compare versions

Comparing version 0.0.4-dev to 0.0.5-dev

lib/validate/array.js

10

lib/Check.js

@@ -35,5 +35,6 @@ 'use strict'

!validate.number[rule] &&
!validate.array[rule] &&
!validate.object[rule] &&
!validate.function[rule]
) {
) {
return __unknownRule(value, rule)

@@ -58,2 +59,3 @@ }

// object cases
case 'isSet':
case 'isObject':

@@ -68,5 +70,9 @@ case 'isArray':

break
// array cases
case 'isIn':
_match = validate.array[rule](value, _compare)
break
// function cases
case 'isFunction':
// case 'returnPromise':
// case 'returnPromise':
_match = _compare === validate.function[rule](value)

@@ -73,0 +79,0 @@ break

3

lib/validate/index.js

@@ -6,5 +6,6 @@ 'use strict'

number: require('./number'),
object: require('./object')
object: require('./object'),
array: require('./array')
}
module.exports = validate

@@ -6,2 +6,5 @@ 'use strict'

const object = {
isSet: function (value) {
return value !== null && value !== undefined
},
isObject: function (value) {

@@ -8,0 +11,0 @@ return value && typeof value === 'object'

{
"name": "checkv",
"version": "0.0.4-dev",
"description": "validator checker",
"version": "0.0.5-dev",
"description": "javascript idiomatic validator",
"main": "main.js",

@@ -34,4 +34,4 @@ "dependencies": {

],
"author": "Simone Sanfratello <simone.sanfra@gmail.com>",
"author": "Simone Sanfratello <simone@braceslab.com>",
"license": "MIT"
}
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