Skip to content

Commit

Permalink
chore: merge configuration before checking validity
Browse files Browse the repository at this point in the history
  • Loading branch information
gentlementlegen committed May 15, 2024
1 parent 40acec4 commit 41938f6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/configuration/config-reader.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ try {
}

if (program.settings) {
const settings = JSON.parse(program.settings);
const settings = merge(configuration, JSON.parse(program.settings));
if (validateIncentivesConfiguration.test(settings)) {
configuration = merge(configuration, settings);
configuration = settings;
} else {
console.warn("Invalid incentives configuration detected, will revert to defaults.");
for (const error of validateIncentivesConfiguration.errors(settings)) {
Expand Down

0 comments on commit 41938f6

Please sign in to comment.