Skip to content

Commit

Permalink
Use null if there's no tagTemplate set
Browse files Browse the repository at this point in the history
  • Loading branch information
webpro committed Aug 15, 2021
1 parent 3ad6bb0 commit 9dcc05c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ class ConventionalChangelog extends Plugin {
const { version } = this.getContext();
const { isIncrement } = this.config;
const { latestTag, secondLatestTag, tagTemplate } = this.config.getContext();
const currentTag = isIncrement ? (tagTemplate ? tagTemplate.replace('${version}', version) : version) : latestTag;
const currentTag = isIncrement ? (tagTemplate ? tagTemplate.replace('${version}', version) : null) : latestTag;
const previousTag = isIncrement ? latestTag : secondLatestTag;
const releaseCount = opts.releaseCount === 0 ? 0 : isIncrement ? 1 : 2;
const options = Object.assign({}, { releaseCount }, this.options);
Expand Down

0 comments on commit 9dcc05c

Please sign in to comment.