@efebia/pino-mongodb 0.0.1 → 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
File without changes
@@ -7,7 +7,6 @@ exports.defaultOption = void 0;
7
7
  const mongodb_1 = require("mongodb");
8
8
  const pino_abstract_transport_1 = __importDefault(require("pino-abstract-transport"));
9
9
  const stream_1 = require("stream");
10
- const package_json_1 = require("../package.json");
11
10
  const log_js_1 = __importDefault(require("./log.js"));
12
11
  const queue_js_1 = require("./queue.js");
13
12
  exports.defaultOption = {
@@ -23,9 +22,9 @@ exports.defaultOption = {
23
22
  const bulkTransport = async (opts) => {
24
23
  const { uri, database: databaseName, collection: collectionName, clientOptions, queueOptions } = Object.assign(Object.assign({}, exports.defaultOption), opts);
25
24
  if (!uri)
26
- throw new Error(`${package_json_1.name}: URI_NOT_SPECIFIED`);
25
+ throw new Error(`@efebia/pino-mongodb: URI_NOT_SPECIFIED`);
27
26
  if (!collectionName)
28
- throw new Error(`${package_json_1.name}: COLLECTION_NAME_NOT_SPECIFIED`);
27
+ throw new Error(`@efebia/pino-mongodb: COLLECTION_NAME_NOT_SPECIFIED`);
29
28
  const client = new mongodb_1.MongoClient(uri, clientOptions);
30
29
  await client.connect();
31
30
  const db = client.db(databaseName);
File without changes
File without changes
File without changes
File without changes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@efebia/pino-mongodb",
3
- "version": "0.0.1",
3
+ "version": "0.0.2",
4
4
  "license": "MIT",
5
5
  "dependencies": {
6
6
  "mongodb": "^4.8.1",
package/lib/package.json DELETED
@@ -1,20 +0,0 @@
1
- {
2
- "name": "@efebia/pino-mongodb",
3
- "version": "0.0.1",
4
- "license": "MIT",
5
- "dependencies": {
6
- "mongodb": "^4.8.1",
7
- "pino-abstract-transport": "^1.0.0"
8
- },
9
- "devDependencies": {
10
- "@types/node": "18",
11
- "typescript": "^4.7.4"
12
- },
13
- "files": [
14
- "/lib"
15
- ],
16
- "scripts": {
17
- "build": "tsc"
18
- },
19
- "main": "./lib"
20
- }