log on bad requests
This commit is contained in:
@@ -50,5 +50,7 @@ func Coffee(writer http.ResponseWriter, request *http.Request) {
|
|||||||
|
|
||||||
if incoming_msg.Token == mattermost_token || incoming_msg.Token == test_token {
|
if incoming_msg.Token == mattermost_token || incoming_msg.Token == test_token {
|
||||||
json.NewEncoder(writer).Encode(&reply{Response_type: "comment", Text: "@omorud"})
|
json.NewEncoder(writer).Encode(&reply{Response_type: "comment", Text: "@omorud"})
|
||||||
|
} else {
|
||||||
|
log.Printf("Invalid request received with token: %v", incoming_msg.Token)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user