From 935bdd0ddd393457a37fea237511d1027a8d0ed4 Mon Sep 17 00:00:00 2001 From: sam boyer Date: Fri, 2 Sep 2016 18:40:07 -0400 Subject: [PATCH] Use generated semver string if orig is empty --- version.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/version.go b/version.go index 15520501..1e150293 100644 --- a/version.go +++ b/version.go @@ -301,7 +301,11 @@ type semVersion struct { } func (v semVersion) String() string { - return v.sv.Original() + str := v.sv.Original() + if str == "" { + str = v.sv.String() + } + return str } func (r semVersion) Type() string {