diff --git a/lib/assert.js b/lib/assert.js index 6963ef41307..a37329caf2d 100644 --- a/lib/assert.js +++ b/lib/assert.js @@ -27,7 +27,7 @@ const { codes: { ERR_INVALID_ARG_VALUE, ERR_INVALID_RETURN_VALUE } } = require('internal/errors'); -const { AssertionError } = require('internal/assert'); +const AssertionError = require('internal/assert/assertion_error'); const { openSync, closeSync, readSync } = require('fs'); const { inspect, types: { isPromise, isRegExp } } = require('util'); const { EOL } = require('internal/constants'); diff --git a/lib/internal/assert.js b/lib/internal/assert/assertion_error.js similarity index 99% rename from lib/internal/assert.js rename to lib/internal/assert/assertion_error.js index 4e059db6b9d..a13a610da1a 100644 --- a/lib/internal/assert.js +++ b/lib/internal/assert/assertion_error.js @@ -405,6 +405,4 @@ class AssertionError extends Error { } } -module.exports = { - AssertionError -}; +module.exports = AssertionError; diff --git a/node.gyp b/node.gyp index e3ff9da6b95..5596c6e491c 100644 --- a/node.gyp +++ b/node.gyp @@ -85,7 +85,7 @@ 'lib/vm.js', 'lib/worker_threads.js', 'lib/zlib.js', - 'lib/internal/assert.js', + 'lib/internal/assert/assertion_error.js', 'lib/internal/async_hooks.js', 'lib/internal/buffer.js', 'lib/internal/cli_table.js',