Fix panic on invalid version strings

This commit is contained in:
Peter Dyer committed 2018-08-05 00:25:27 +01:00
1 parent 6515a9bf04
commit 8d7ff22fed
1 file changed
+4
+4
View File
@@ -53,6 +53,10 @@ func splitDep(dep string) (string, string, string) {
return match
})
if len(split) == 0 {
return "", "", ""
}
if len(split) == 1 {
return split[0], "", ""
}