diff --git a/lib/error/validation.js b/lib/error/validation.js index 9d4453762a5..ccae07adff1 100644 --- a/lib/error/validation.js +++ b/lib/error/validation.js @@ -4,10 +4,9 @@ 'use strict'; -const MongooseError = require('./'); +const MongooseError = require('./mongooseError'); const util = require('util'); - class ValidationError extends MongooseError { /** * Document Validation Error @@ -108,4 +107,4 @@ function _generateMessage(err) { * Module exports */ -module.exports = exports = ValidationError; +module.exports = ValidationError; diff --git a/package.json b/package.json index d25ea97ac89..286f621b812 100644 --- a/package.json +++ b/package.json @@ -32,12 +32,13 @@ "sift": "7.0.1" }, "devDependencies": { + "@babel/core": "7.10.5", + "@babel/preset-env": "7.10.4", "acquit": "1.x", "acquit-ignore": "0.1.x", "acquit-require": "0.1.x", "async": "2.6.2", - "babel-loader": "7.1.4", - "babel-preset-es2015": "6.24.1", + "babel-loader": "8.1.0", "benchmark": "2.1.4", "bluebird": "3.5.5", "chalk": "2.4.2", @@ -62,7 +63,7 @@ "uuid": "2.0.3", "uuid-parse": "1.0.0", "validator": "10.8.0", - "webpack": "4.16.4" + "webpack": "4.44.0" }, "directories": { "lib": "./lib/mongoose" diff --git a/webpack.base.config.js b/webpack.base.config.js index 33327617e57..1b2141aab16 100644 --- a/webpack.base.config.js +++ b/webpack.base.config.js @@ -11,7 +11,7 @@ module.exports = { ], loader: 'babel-loader', options: { - presets: ['es2015'] + presets: ['@babel/preset-env'] } } ]