rkt trust: print error when --prefix discovery finds nothing

This commit is contained in:
Vito Caputo
2015-02-06 19:04:17 -08:00
parent be25d3d51e
commit 7b2fb47ca8
+4
View File
@@ -147,6 +147,10 @@ func getPubKeyLocations(prefix string, args []string) ([]string, error) {
return nil, fmt.Errorf("--prefix meta discovery error: %v", err)
}
if len(kls) == 0 {
return nil, fmt.Errorf("meta discovery on %s resulted in no keys", prefix)
}
return kls, nil
}