Skip to content

Commit

Permalink
fix: check publish props only in verify ones are undefined
Browse files Browse the repository at this point in the history
  • Loading branch information
pvdlg committed Mar 7, 2018
1 parent 65d6e93 commit 65fd45f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
const {castArray} = require('lodash');
const {defaultTo, castArray} = require('lodash');
const verifyChangelog = require('./lib/verify');
const prepareChangelog = require('./lib/prepare');

Expand All @@ -10,7 +10,7 @@ async function verifyConditions(pluginConfig, {options}) {
const preparePlugin =
castArray(options.prepare).find(config => config.path && config.path === '@semantic-release/changelog') || {};

pluginConfig.changelogFile = pluginConfig.changelogFile || preparePlugin.changelogFile;
pluginConfig.changelogFile = defaultTo(pluginConfig.changelogFile, preparePlugin.changelogFile);
}
await verifyChangelog(pluginConfig);
verified = true;
Expand Down

0 comments on commit 65fd45f

Please sign in to comment.