diff options
Diffstat (limited to 'currentVersions.go')
| -rw-r--r-- | currentVersions.go | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/currentVersions.go b/currentVersions.go index db2ebfa..7f64335 100644 --- a/currentVersions.go +++ b/currentVersions.go @@ -55,6 +55,11 @@ func (repo *Repo) setDevelVersion() { func (repo *Repo) setUserVersion() { bname := repo.GetUserBranchName() + if !repo.Exists(filepath.Join(".git/refs/heads", bname)) { + // the user branch does not exist at this time + repo.UserVersion = "uerr" + return + } v, err := repo.gitVersionByName(bname) if err == nil { repo.UserVersion = v |
