Skip to content

Commit e5eafa3

Browse files
committed
fallbacks
1 parent 35dc54a commit e5eafa3

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

Lombiq.NodeJs.Extensions/scripts/get-config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ function getConfig({ directory, verbose }) {
2828
const log = (message) => { if (verbose) process.stderr.write(message); };
2929
const logLine = (message) => log(message + '\n');
3030

31-
const packageJsonPath = path.resolve(directory, 'package.json');
31+
const packageJsonPath = path.resolve(directory ?? '.', 'package.json');
3232
let nodejsExtensionsConfig = {};
3333

3434
log(`Reading configuration from ${packageJsonPath}... `);

Lombiq.NodeJs.Extensions/scripts/get-path.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ function getSolutionDir(initialDirectory) {
6767
}
6868

6969
function getPathContext() {
70-
const initialDirectory = getProjectDirectory();
70+
const initialDirectory = getProjectDirectory() ?? '.';
7171
const config = getConfig({ directory: initialDirectory, verbose: verbose });
7272
const locationType = getLocationType(locationArgument, initialDirectory, config, type);
7373

0 commit comments

Comments
 (0)