diff --git a/app/lib/tag.js b/app/lib/tag.js index 16c22d0..d799032 100644 --- a/app/lib/tag.js +++ b/app/lib/tag.js @@ -33,7 +33,13 @@ export default class Tag { } try { - const changelog = await github.repos.compareCommits({ owner, repo, base: tags.data.shift().name, head: 'master' }) + let tags = await this.getTags() + + if (tags.length === 0) { + return `Version ${this.version}` + } + + const changelog = await github.repos.compareCommits({ owner, repo, base: tags.shift().name, head: 'master' }) return changelog.data.commits .map(