Socket
Socket
Sign inDemoInstall

dambreaker-mongo

Package Overview
Dependencies
133
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.0.1 to 0.0.2

5

lib/dambreaker-mongo.js

@@ -47,3 +47,4 @@ /*!

//https://github.com/mongodb/node-mongodb-native/blob/3.0.0/CHANGES_3.0.0.md#api-changes
connectionString = user && password ? `mongodb://${user}:${password}@${host}:${port}/${database}` : `mongodb://${host}:${port}/${database}`;
const portStr = port ? ":" + port : ""; //port is optional
connectionString = user && password ? `mongodb://${user}:${password}@${host}${portStr}/${database}` : `mongodb://${host}${portStr}/${database}`;
console.log("Mongo connection", connectionString);

@@ -56,3 +57,3 @@ client = await MongoClient.connect(connectionString);

}
if (!db.collection) throw new Error("No collection for database ${host}:${port}.", { host, port, database });
if (!db.collection) throw new Error("No collection in database ${database} on ${host}:${port}.", { host, port, database });

@@ -59,0 +60,0 @@ this.connections[dbName] = { db, client, server };

2

package.json
{
"name": "dambreaker-mongo",
"version": "0.0.1",
"version": "0.0.2",
"description": "Mongo client for dambreaker",

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc