summaryrefslogtreecommitdiff
path: root/pkg/trust/trust.go
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2020-10-06 10:15:04 +0200
committerGitHub <noreply@github.com>2020-10-06 10:15:04 +0200
commit80a2317ca20b0e5e1cd064a8962beed642be3a36 (patch)
tree0730915a611542bf028d5b9c66ace1390a6c036f /pkg/trust/trust.go
parentf584d47a9d0c050c3b39793a73b0aba17b45e8ba (diff)
parentd4aa89bb40b3a2c1730c9bff31a681007a3feb97 (diff)
downloadpodman-80a2317ca20b0e5e1cd064a8962beed642be3a36.tar.gz
podman-80a2317ca20b0e5e1cd064a8962beed642be3a36.tar.bz2
podman-80a2317ca20b0e5e1cd064a8962beed642be3a36.zip
Merge pull request #7929 from kolyshkin/nits-err
Nits
Diffstat (limited to 'pkg/trust/trust.go')
-rw-r--r--pkg/trust/trust.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/pkg/trust/trust.go b/pkg/trust/trust.go
index 2348bc410..a61e0ef10 100644
--- a/pkg/trust/trust.go
+++ b/pkg/trust/trust.go
@@ -117,7 +117,7 @@ func LoadAndMergeConfig(dirPath string) (*RegistryConfiguration, error) {
var config RegistryConfiguration
err = yaml.Unmarshal(configBytes, &config)
if err != nil {
- return nil, errors.Wrapf(err, "Error parsing %s", configPath)
+ return nil, errors.Wrapf(err, "error parsing %s", configPath)
}
if config.DefaultDocker != nil {
if mergedConfig.DefaultDocker != nil {
@@ -226,10 +226,10 @@ func GetPolicy(policyPath string) (PolicyContent, error) {
var policyContentStruct PolicyContent
policyContent, err := ioutil.ReadFile(policyPath)
if err != nil {
- return policyContentStruct, errors.Wrapf(err, "unable to read policy file %s", policyPath)
+ return policyContentStruct, errors.Wrap(err, "unable to read policy file")
}
if err := json.Unmarshal(policyContent, &policyContentStruct); err != nil {
- return policyContentStruct, errors.Wrapf(err, "could not parse trust policies")
+ return policyContentStruct, errors.Wrapf(err, "could not parse trust policies from %s", policyPath)
}
return policyContentStruct, nil
}