Fix typo & options

This commit is contained in:
Strencher 2022-12-31 17:44:01 +01:00
parent 9875068228
commit 97138afb7d
1 changed files with 2 additions and 2 deletions

View File

@ -145,7 +145,7 @@ const Webpack = {
},
/**
* Finds akk modules using its code.
* Finds all modules using its code.
* @param {RegEx} regex A regular expression to use to filter modules
* @param {object} [options] Options to configure the search
* @param {Boolean} [options.defaultExport=true] Whether to return default export when matching the default export
@ -153,7 +153,7 @@ const Webpack = {
* @return {Any[]}
*/
getAllByRegex(regex, options = {}) {
return WebpackModules.getModule(Filters.byRegex(regex), options);
return WebpackModules.getModule(Filters.byRegex(regex), Object.assign({}, options, {first: true}));
},
/**