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

functionality

Package Overview
Dependencies
Maintainers
1
Versions
13
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

functionality - npm Package Compare versions

Comparing version 2.0.1 to 2.0.2

2

lib/index.js

@@ -50,3 +50,3 @@ var Masquerade = require('./Masquerade.js'),

if(Masquerade.match([mask], [value])) return next();
return next(true);
return false;
}).withToString(function() {

@@ -53,0 +53,0 @@ return "Optional " + Masquerade.type(mask);

{
"name": "functionality",
"version": "2.0.1",
"version": "2.0.2",
"description": "Simple function overloading for JavaScript",

@@ -5,0 +5,0 @@ "author": "Sierra Softworks",

@@ -50,2 +50,15 @@ var fn = require('../');

});
it('should not match arguments of a different type', function() {
var f = fn.on(fn.opt(Number), function() {
return false;
}).or(function() {
return true;
}).compile();
f().should.be.false;
f(1).should.be.false;
f(10).should.be.false;
f('10').should.be.true;
});
});

@@ -52,0 +65,0 @@

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