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

mongojs

Package Overview
Dependencies
Maintainers
2
Versions
105
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mongojs - npm Package Compare versions

Comparing version 0.2.6 to 0.3.0

untitled

4

index.js

@@ -144,2 +144,6 @@ var mongo = require('mongodb');

Collection.prototype.close = function() {
this.close();
};
Object.keys(mongo.Collection.prototype).forEach(function(name) { // we just wanna proxy any remaining methods on collections

@@ -146,0 +150,0 @@ if (!Collection.prototype[name] && typeof mongo.Collection.prototype[name] === 'function') {

4

package.json

@@ -5,3 +5,3 @@ {

"keywords": ["mongo", "db", "mongodb"],
"version":"0.2.6",
"version":"0.3.0",
"homepage" : "https://github.com/gett/mongojs",

@@ -11,3 +11,3 @@ "author": "Ge.tt <hello@ge.tt>",

"Mathias Buus Madsen <m@ge.tt>",
"Ian Jorgensen <i@ge.tt"
"Ian Jorgensen <i@ge.tt>"
],

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

@@ -24,5 +24,9 @@ # mongojs

var db = require('mongojs').connect('username:password@example.com/mydb', ['mycollection']);
// connect now, and worry about collections later
var db = require('mongojs').connect('mydb');
var mycollection = db.collection('mycollection');
```
After we connected to can query or update the database just how we would using the mongo API with the exception that we use a callback
After we connected we can query or update the database just how we would using the mongo API with the exception that we use a callback
The format for callbacks is always `callback(error, value)` where error is null if no exception has occured.

@@ -29,0 +33,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