Skip to content

Daijin no kadai api #9

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

Open
wants to merge 8 commits into
base: master
Choose a base branch
from

Conversation

ookura-mf
Copy link

No description provided.

Copy link
Owner

@mf-sakura mf-sakura left a comment

Choose a reason for hiding this comment

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

@ookura-mf
コメントした所以外は良さそうに思います!

Comment on lines +71 to +72
fmt.Fprint(w, fmt.Sprintf("Only POST method is permitted\n"))
return
Copy link
Owner

Choose a reason for hiding this comment

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

これだと200ステータスで帰ってしまうので、squareHandler同様にステータス書き込みが必要です。

Copy link
Author

Choose a reason for hiding this comment

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

あぁ、確かにそうですね
追記しました!

@@ -74,6 +86,42 @@ func incrementHandler(w http.ResponseWriter, req *http.Request) {
fmt.Fprint(w, fmt.Sprintf("Value of Counter is %d \n", counter))
}

func fizzbuzzHandler(w http.ResponseWriter, req *http.Request) {
Copy link
Owner

Choose a reason for hiding this comment

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

fizzBuzzでcamelCaseにするか、固有名詞としてfizzbuzzにするか、どちらが良いんだろうかと思いました。
camelCaseを意識できているか気になってのコメントです。
把握はできていれば、後は好みなのでどちらでも良いと思います。

Copy link
Author

Choose a reason for hiding this comment

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

fizzbuzzで固有名詞のつもりでした 👀
javaとかswiftとか書いてたのでcamelCaseは割となじんでます(たまに忘れる・・・

@ookura-mf ookura-mf marked this pull request as ready for review April 1, 2020 14:42
@mf-sakura
Copy link
Owner

@ookura-mf
LGTMです〜

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants