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

objectid

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

objectid - npm Package Compare versions

Comparing version 3.0.1 to 3.1.0

7

index.js

@@ -15,2 +15,9 @@ var inherits = require('util').inherits

var equals = function (oidA, oidB) {
// curried
if (arguments.length === 1) {
return function (oidB) {
return equals(oidA, oidB)
}
}
if (oidA === oidB) { return true; }

@@ -17,0 +24,0 @@ if (!oidA || !oidB) { return false }

2

package.json
{
"name": "objectid",
"version": "3.0.1",
"version": "3.1.0",
"description": "mongodb objectid utilities",

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

@@ -31,2 +31,3 @@ # objectid

### ObjectId.equals(oidA, oidB) => Boolean
Curried to support creating equality predicates.

@@ -33,0 +34,0 @@ ### ObjectId.tryParse(oid, out, as) => Boolean

@@ -124,2 +124,9 @@ var chai = require('chai')

})
it('curries arguments', function () {
var oidA = ObjectId()
var eq = ObjectId.equals(oidA)
eq.should.be.a('function')
eq('sdfsdf').should.equal(false)
eq(oidA).should.equal(true)
})
})

@@ -126,0 +133,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