Skip to content

Commit 0e094f3

Browse files
committed
schema, specs-go: fix lint errors
Signed-off-by: Stephen Day <[email protected]>
1 parent d3cd202 commit 0e094f3

File tree

6 files changed

+6
-7
lines changed

6 files changed

+6
-7
lines changed

schema/backwards_compatibility_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import (
2121

2222
"github.com/opencontainers/go-digest"
2323
"github.com/opencontainers/image-spec/schema"
24-
"github.com/opencontainers/image-spec/specs-go/v1"
24+
v1 "github.com/opencontainers/image-spec/specs-go/v1"
2525
)
2626

2727
var compatMap = map[string]string{

schema/loader.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ type fsLoader struct {
7878
}
7979

8080
// JsonSource implements gojsonschema.JSONLoader.JsonSource. The "Json" capitalization needs to be maintained to conform to the interface.
81-
func (l *fsLoader) JsonSource() interface{} { // nolint: golint
81+
func (l *fsLoader) JsonSource() interface{} { // revive:disable-line:var-naming
8282
return l.source
8383
}
8484

@@ -117,7 +117,7 @@ func decodeJSONUsingNumber(r io.Reader) (interface{}, error) {
117117
}
118118

119119
// JsonReference implements gojsonschema.JSONLoader.JsonReference. The "Json" capitalization needs to be maintained to conform to the interface.
120-
func (l *fsLoader) JsonReference() (gojsonreference.JsonReference, error) { // nolint: golint
120+
func (l *fsLoader) JsonReference() (gojsonreference.JsonReference, error) { // revive:disable-line:var-naming
121121
return gojsonreference.NewJsonReference(l.JsonSource().(string))
122122
}
123123

schema/schema.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ package schema
1717
import (
1818
"net/http"
1919

20-
"github.com/opencontainers/image-spec/specs-go/v1"
20+
v1 "github.com/opencontainers/image-spec/specs-go/v1"
2121
)
2222

2323
// Media types for the OCI image formats

schema/spec_test.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,6 @@ func validate(t *testing.T, name string) {
9595
}
9696

9797
for _, err := range errs {
98-
// TOOD(stevvooe): This is nearly useless without file, line no.
9998
printFields(t, "invalid", example.Mediatype, example.Title)
10099
t.Error(err)
101100
fmt.Println(example.Body, "---")

specs-go/v1/index.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import "github.com/opencontainers/image-spec/specs-go"
2121
type Index struct {
2222
specs.Versioned
2323

24-
// MediaType specificies the type of this document data structure e.g. `application/vnd.oci.image.index.v1+json`
24+
// MediaType specifies the type of this document data structure e.g. `application/vnd.oci.image.index.v1+json`
2525
MediaType string `json:"mediaType,omitempty"`
2626

2727
// Manifests references platform specific manifests.

specs-go/v1/manifest.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import "github.com/opencontainers/image-spec/specs-go"
2020
type Manifest struct {
2121
specs.Versioned
2222

23-
// MediaType specificies the type of this document data structure e.g. `application/vnd.oci.image.manifest.v1+json`
23+
// MediaType specifies the type of this document data structure e.g. `application/vnd.oci.image.manifest.v1+json`
2424
MediaType string `json:"mediaType,omitempty"`
2525

2626
// Config references a configuration object for a container, by digest.

0 commit comments

Comments
 (0)