Skip to content

Commit

Permalink
Changed db connection logic to resolve issue with reusing already ope…
Browse files Browse the repository at this point in the history
…n connection
  • Loading branch information
johnpudd committed Apr 24, 2014
1 parent 5a10315 commit 54ac0ee
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions db/db.client.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,9 @@ var MongoClient = mongo.MongoClient,
Server = require('mongodb').Server,
BSON = mongo.BSONPure;

var mongoclient = new MongoClient(new Server("127.0.0.1", 27017), {native_parser: true});

exports.getDbClient = function(){
return mongoclient;
return new MongoClient(new Server("127.0.0.1", 27017), {native_parser: true});
};

exports.dbName = function(){
Expand Down

0 comments on commit 54ac0ee

Please sign in to comment.