Skip to content

Fix a few lint issues#1684

Merged
jonjohnsonjr merged 1 commit intogoogle:mainfrom
jonjohnsonjr:lint
May 1, 2023
Merged

Fix a few lint issues#1684
jonjohnsonjr merged 1 commit intogoogle:mainfrom
jonjohnsonjr:lint

Conversation

@jonjohnsonjr
Copy link
Copy Markdown
Collaborator

No description provided.

@codecov-commenter
Copy link
Copy Markdown

Codecov Report

Merging #1684 (d2feb1d) into main (43710a9) will increase coverage by 0.03%.
The diff coverage is 75.00%.

@@            Coverage Diff             @@
##             main    #1684      +/-   ##
==========================================
+ Coverage   72.81%   72.84%   +0.03%     
==========================================
  Files         121      121              
  Lines        9633     9629       -4     
==========================================
  Hits         7014     7014              
+ Misses       1941     1939       -2     
+ Partials      678      676       -2     
Impacted Files Coverage Δ
pkg/name/registry.go 97.05% <0.00%> (-2.95%) ⬇️
pkg/crane/push.go 100.00% <100.00%> (ø)
pkg/legacy/tarball/write.go 67.96% <100.00%> (+0.78%) ⬆️
pkg/v1/remote/write.go 62.68% <100.00%> (+0.39%) ⬆️
pkg/v1/tarball/image.go 76.20% <100.00%> (ø)

Copy link
Copy Markdown
Contributor

@imjasonh imjasonh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, feel free to ignore these nits.

}

func (k *fakeKeychain) Resolve(target Resource) (Authenticator, error) {
func (k *fakeKeychain) Resolve(_ Resource) (Authenticator, error) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
func (k *fakeKeychain) Resolve(_ Resource) (Authenticator, error) {
func (k *fakeKeychain) Resolve(Resource) (Authenticator, error) {

}

func (m *MockClient) NegotiateAPIVersion(ctx context.Context) {
func (m *MockClient) NegotiateAPIVersion(_ context.Context) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
func (m *MockClient) NegotiateAPIVersion(_ context.Context) {
func (m *MockClient) NegotiateAPIVersion(context.Context) {

}

func (r *errReader) Read(p []byte) (int, error) {
func (r *errReader) Read(_ []byte) (int, error) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
func (r *errReader) Read(_ []byte) (int, error) {
func (r *errReader) Read([]byte) (int, error) {

}

func (e *errReadCloser) Read(p []byte) (int, error) {
func (e *errReadCloser) Read(_ []byte) (int, error) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
func (e *errReadCloser) Read(_ []byte) (int, error) {
func (e *errReadCloser) Read([]byte) (int, error) {

}

func (t *mockTransport) RoundTrip(in *http.Request) (out *http.Response, err error) {
func (t *mockTransport) RoundTrip(_ *http.Request) (out *http.Response, err error) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
func (t *mockTransport) RoundTrip(_ *http.Request) (out *http.Response, err error) {
func (t *mockTransport) RoundTrip(*http.Request) (out *http.Response, err error) {

@jonjohnsonjr jonjohnsonjr merged commit 370e8a5 into google:main May 1, 2023
@jonjohnsonjr jonjohnsonjr deleted the lint branch May 1, 2023 18:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants