arnaucube
arnaucube/thoughtsPublic Self-hosted repository
thoughts/node_modules/mongoose/lib/errors/document.js
node_modules/mongoose/lib/errors/document.jsRaw
 1
 2/*!
 3 * Module requirements
 4 */
 5
 6var MongooseError = require('../error')
 7
 8/**
 9 * Document Error
10 *
11 * @param {String} msg
12 * @inherits MongooseError
13 * @api private
14 */
15
16function DocumentError (msg) {
17  MongooseError.call(this, msg);
18  Error.captureStackTrace(this, arguments.callee);
19  this.name = 'DocumentError';
20};
21
22/*!
23 * Inherits from MongooseError.
24 */
25
26DocumentError.prototype.__proto__ = MongooseError.prototype;
27
28/*!
29 * Module exports.
30 */
31
32module.exports = exports = DocumentError;