Initial commit
This commit is contained in:
32
node_modules/mongodb/lib/dynamic_loaders.js
generated
vendored
Normal file
32
node_modules/mongodb/lib/dynamic_loaders.js
generated
vendored
Normal file
@@ -0,0 +1,32 @@
|
||||
'use strict';
|
||||
|
||||
let collection;
|
||||
let cursor;
|
||||
let db;
|
||||
|
||||
function loadCollection() {
|
||||
if (!collection) {
|
||||
collection = require('./collection');
|
||||
}
|
||||
return collection;
|
||||
}
|
||||
|
||||
function loadCursor() {
|
||||
if (!cursor) {
|
||||
cursor = require('./cursor');
|
||||
}
|
||||
return cursor;
|
||||
}
|
||||
|
||||
function loadDb() {
|
||||
if (!db) {
|
||||
db = require('./db');
|
||||
}
|
||||
return db;
|
||||
}
|
||||
|
||||
module.exports = {
|
||||
loadCollection,
|
||||
loadCursor,
|
||||
loadDb
|
||||
};
|
||||
Reference in New Issue
Block a user