mirror of
https://github.com/distribution/distribution.git
synced 2025-09-12 21:28:59 +00:00
Fix gometalint errors
Signed-off-by: Manish Tomar <manish.tomar@docker.com>
This commit is contained in:
@@ -133,10 +133,7 @@ func pathFor(spec pathSpec) (string, error) {
|
||||
|
||||
return path.Join(append(append(repoPrefix, v.name, "_manifests", "revisions"), components...)...), nil
|
||||
case manifestRevisionLinkPathSpec:
|
||||
root, err := pathFor(manifestRevisionPathSpec{
|
||||
name: v.name,
|
||||
revision: v.revision,
|
||||
})
|
||||
root, err := pathFor(manifestRevisionPathSpec(v))
|
||||
|
||||
if err != nil {
|
||||
return "", err
|
||||
@@ -156,10 +153,7 @@ func pathFor(spec pathSpec) (string, error) {
|
||||
|
||||
return path.Join(root, v.tag), nil
|
||||
case manifestTagCurrentPathSpec:
|
||||
root, err := pathFor(manifestTagPathSpec{
|
||||
name: v.name,
|
||||
tag: v.tag,
|
||||
})
|
||||
root, err := pathFor(manifestTagPathSpec(v))
|
||||
|
||||
if err != nil {
|
||||
return "", err
|
||||
@@ -167,10 +161,7 @@ func pathFor(spec pathSpec) (string, error) {
|
||||
|
||||
return path.Join(root, "current", "link"), nil
|
||||
case manifestTagIndexPathSpec:
|
||||
root, err := pathFor(manifestTagPathSpec{
|
||||
name: v.name,
|
||||
tag: v.tag,
|
||||
})
|
||||
root, err := pathFor(manifestTagPathSpec(v))
|
||||
|
||||
if err != nil {
|
||||
return "", err
|
||||
@@ -178,11 +169,7 @@ func pathFor(spec pathSpec) (string, error) {
|
||||
|
||||
return path.Join(root, "index"), nil
|
||||
case manifestTagIndexEntryLinkPathSpec:
|
||||
root, err := pathFor(manifestTagIndexEntryPathSpec{
|
||||
name: v.name,
|
||||
tag: v.tag,
|
||||
revision: v.revision,
|
||||
})
|
||||
root, err := pathFor(manifestTagIndexEntryPathSpec(v))
|
||||
|
||||
if err != nil {
|
||||
return "", err
|
||||
|
Reference in New Issue
Block a user