Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
'use strict';
/**
* Dependencies
*/
const ObjectID = require('monk/node_modules/mongoskin').ObjectID;
/**
* Expose utilities
*/
exports.isObjectID = isObjectID;
/**
* Utilities
*/
function isObjectID (value) {
return !!(value && value.constructor === ObjectID);
}
'use strict';
/**
* Dependencies
*/
const ObjectID = require('monk/node_modules/mongoskin').ObjectID;
/**
* Expose utilities
*/
exports.isObjectID = isObjectID;
/**
* Utilities
*/
function isObjectID (value) {
return !!(value && value.constructor === ObjectID);
}
"use strict";
var _slicedToArray = function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { var _arr = []; for (var _iterator = arr[Symbol.iterator](), _step; !(_step = _iterator.next()).done;) { _arr.push(_step.value); if (i && _arr.length === i) break; } return _arr; } else { throw new TypeError("Invalid attempt to destructure non-iterable instance"); } };
var _prototypeProperties = function (child, staticProps, instanceProps) { if (staticProps) Object.defineProperties(child, staticProps); if (instanceProps) Object.defineProperties(child.prototype, instanceProps); };
var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } };
/**
* Dependencies
*/
var ObjectID = require("monk/node_modules/mongoskin").ObjectID;
var Class = require("class-extend");
var pluralize = require("pluralize");
var compose = require("koa-compose");
var result = require("lodash.result");
var monk = require("monk");
var wrap = require("co-monk");
var util = require("./util");
var is = require("is_js");
/**
* Mongorito
*
* Main class, manages mongodb connection and collections
*/