refactor(CLI): Remove redundant arg

`path.resolve` by default resolves against working dir
This commit is contained in:
Mariusz Nowak 2021-01-20 15:51:07 +01:00 committed by Mariusz Nowak
parent 533106515e
commit 8451b8908c

View File

@ -24,7 +24,7 @@ module.exports = async () => {
'INVALID_SERVICE_CONFIG_PATH'
);
}
const customConfigPath = path.resolve(process.cwd(), customConfigName);
const customConfigPath = path.resolve(customConfigName);
if (process.cwd() !== path.dirname(customConfigPath)) {
throw new ServerlessError(
'Invalid "--config" value: config cannot be nested in sub-directory',