Blame view

node_modules/mongoose/lib/errors/overwriteModel.js 533 Bytes
46de8790   Tarpit Grover   first commit
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30

/*!
 * Module dependencies.
 */

var MongooseError = require('../error');

/*!
 * OverwriteModel Error constructor.
 *
 * @inherits MongooseError
 */

function OverwriteModelError (name) {
  MongooseError.call(this, 'Cannot overwrite `' + name + '` model once compiled.');
  Error.captureStackTrace(this, arguments.callee);
  this.name = 'OverwriteModelError';
};

/*!
 * Inherits from MongooseError.
 */

OverwriteModelError.prototype.__proto__ = MongooseError.prototype;

/*!
 * exports
 */

module.exports = OverwriteModelError;