From 139de0f79da5ce72fca230a48857e659b05b3062 Mon Sep 17 00:00:00 2001 From: Jordi Boggiano Date: Tue, 6 Dec 2011 22:18:52 +0100 Subject: [PATCH] Fix handling of git repos with no tag, fixes #146 --- src/Composer/Repository/Vcs/GitDriver.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Composer/Repository/Vcs/GitDriver.php b/src/Composer/Repository/Vcs/GitDriver.php index 3661fe046..1da392667 100644 --- a/src/Composer/Repository/Vcs/GitDriver.php +++ b/src/Composer/Repository/Vcs/GitDriver.php @@ -117,7 +117,7 @@ class GitDriver implements VcsDriverInterface { if (null === $this->tags) { exec(sprintf('cd %s && git tag', escapeshellarg($this->tmpDir)), $output); - $this->tags = array_combine($output, $output); + $this->tags = $output ? array_combine($output, $output) : array(); } return $this->tags;