Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

First code review comments #2

Closed
6 tasks
rantav opened this issue Aug 13, 2017 · 0 comments
Closed
6 tasks

First code review comments #2

rantav opened this issue Aug 13, 2017 · 0 comments

Comments

@rantav
Copy link
Contributor

rantav commented Aug 13, 2017

There's no good way to leave comments in code, so I'll leave them all here

  • The doc.go file looks like a copy of the readme file. First you need to update it. Second - is there a way to automate that?
  • in IsErrorStruct you should use a type switch instead of iterating over an array of string with reflect.TypeOf(x).Name{}
  • in glide.yaml, testify should be a testImport
  • statusCodeToStruct has a switch inside a switch. Rubs me the wrong way. I would extract a function out of the internal switch
  • This doesn't look right
	case http.StatusForbidden:
		var badRequest InvalidFormatResponse
  • Line 78 has commented out code // err = json.Unmarshal(body, &result)
@ik5 ik5 closed this as completed Aug 13, 2017
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

No branches or pull requests

2 participants