Socket
Socket
Sign inDemoInstall

mongoose

Package Overview
Dependencies
Maintainers
0
Versions
883
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mongoose - npm Package Compare versions

Comparing version 1.1.4 to 1.1.5

6

History.md
1.1.5 / 2011-03-14
==================
* Added support for `uri, db, fn` and `uri, fn` signatures for replica sets.
* Improved/extended replica set tests.
1.1.4 / 2011-03-09

@@ -3,0 +9,0 @@ ==================

@@ -162,2 +162,7 @@

if ('function' == typeof database)
callback = database;
else
this.name = database;
uris.forEach(function (uri) {

@@ -179,2 +184,8 @@ var uri = url.parse(uri);

if (!this.name) {
if (callback)
callback(new Error('No database name provided for replica set'));
return;
}
// open connection

@@ -181,0 +192,0 @@ this.doOpenSet(function (err) {

2

lib/mongoose/index.js

@@ -284,3 +284,3 @@

exports.version = '1.1.4';
exports.version = '1.1.5';

@@ -287,0 +287,0 @@ /**

{
"name": "mongoose"
, "description": "Mongoose MongoDB ORM"
, "version": "1.1.4"
, "version": "1.1.5"
, "author": "Guillermo Rauch <guillermo@learnboost.com>"

@@ -6,0 +6,0 @@ , "keywords": ["mongodb", "mongoose", "orm", "data", "datastore", "nosql"]

@@ -166,3 +166,3 @@

mongoose.connectSet(uri, function (err) {
mong.connectSet(uri, function (err) {
should.strictEqual(err, null);

@@ -186,3 +186,3 @@

mongoose.connection.close();
mong.connection.close();
});

@@ -193,2 +193,34 @@ });

'test initializing a new Connection to a replica set': function () {
var uri = process.env.MONGOOSE_SET_TEST_URI;
if (!uri) return;
var mong = new Mongoose(true);
var conn = mong.createSetConnection(uri, function (err) {
should.strictEqual(err, null);
mong.model('ReplSetTwo', new mongoose.Schema({
test: String
}));
var Test = conn.model('ReplSetTwo')
, test = new Test();
test.test = 'aa';
test.save(function (err) {
should.strictEqual(err, null);
Test.findById(test._id, function (err, doc) {
should.strictEqual(err, null);
doc.test.should.eql('aa');
conn.close();
});
});
});
},
'test public exports': function () {

@@ -195,0 +227,0 @@ mongoose.version.should.be.a('string');

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