Skip to content

Commit d30c8cd

Browse files
committed
Fix duplicating tags on re-fetching tags
1 parent cb04682 commit d30c8cd

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/GitChangelog.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -194,6 +194,7 @@ public function fetchTags($force = false): array
194194
$gitPath .= $this->gitPath ?? './.git';
195195

196196
// Get all git tags.
197+
$this->gitTags = [];
197198
$commandResult = 1;
198199
exec("git $gitPath tag --sort=-{$this->options['tagOrderBy']}", $this->gitTags, $commandResult);
199200
if ($commandResult !== 0) {

0 commit comments

Comments
 (0)