Skip to content

Commit

Permalink
return 500(Internal Server Error) if it cannot exec command
Browse files Browse the repository at this point in the history
  • Loading branch information
t-matsuo committed Jun 7, 2021
1 parent e629bba commit 2c50c74
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions webhook.go
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,7 @@ func handleReq(w http.ResponseWriter, r *http.Request) {

if err != nil {
log_err.Printf("Can't call. %s\n", err)
w.WriteHeader(http.StatusInternalServerError)
fmt.Fprintf(w, "Can't call.\n")
} else {
fmt.Fprintf(w, "Called.\n")
Expand Down

0 comments on commit 2c50c74

Please sign in to comment.