Skip to content
This repository was archived by the owner on Aug 7, 2023. It is now read-only.

Commit 4f646b6

Browse files
fcFnArcanemagus
authored andcommitted
Don't specify rulesDir if not found (#843)
1 parent f469e9e commit 4f646b6

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

lib/worker-helpers.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,9 @@ function getArgv(type, config, rules, filePath, fileDir, givenConfigPath) {
176176
if (!_path2.default.isAbsolute(rulesDir)) {
177177
rulesDir = (0, _atomLinter.findCached)(fileDir, rulesDir);
178178
}
179-
argv.push('--rulesdir', rulesDir);
179+
if (rulesDir) {
180+
argv.push('--rulesdir', rulesDir);
181+
}
180182
}
181183
if (configPath) {
182184
argv.push('--config', (0, _resolveEnv2.default)(configPath));

src/worker-helpers.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,9 @@ export function getArgv(type, config, rules, filePath, fileDir, givenConfigPath)
155155
if (!Path.isAbsolute(rulesDir)) {
156156
rulesDir = findCached(fileDir, rulesDir)
157157
}
158-
argv.push('--rulesdir', rulesDir)
158+
if (rulesDir) {
159+
argv.push('--rulesdir', rulesDir)
160+
}
159161
}
160162
if (configPath) {
161163
argv.push('--config', resolveEnv(configPath))

0 commit comments

Comments
 (0)