Skip to content

Commit

Permalink
reverse conditional for style
Browse files Browse the repository at this point in the history
  • Loading branch information
Jason Killian committed Feb 4, 2016
1 parent f24fe3d commit 5bcee13
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/ruleLoader.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,14 +39,14 @@ export function loadRules(ruleConfiguration: {[name: string]: any},
if (ruleConfiguration.hasOwnProperty(ruleName)) {
const ruleValue = ruleConfiguration[ruleName];
const Rule = findRule(ruleName, rulesDirectories);
if (Rule !== undefined) {
if (Rule == null) {
notFoundRules.push(ruleName);
} else {
const all = "all"; // make the linter happy until we can turn it on and off
const allList = (all in enableDisableRuleMap ? enableDisableRuleMap[all] : []);
const ruleSpecificList = (ruleName in enableDisableRuleMap ? enableDisableRuleMap[ruleName] : []);
const disabledIntervals = buildDisabledIntervalsFromSwitches(ruleSpecificList, allList);
rules.push(new Rule(ruleName, ruleValue, disabledIntervals));
} else {
notFoundRules.push(ruleName);
}
}
}
Expand Down

0 comments on commit 5bcee13

Please sign in to comment.