adding verbose init messages

This commit is contained in:
2022-01-10 09:07:03 -06:00
parent 8f477a0c79
commit ac105cbf0d
2 changed files with 10 additions and 1 deletions

View File

@@ -201,8 +201,9 @@ func tmpltTPlinkPost(w http.ResponseWriter, r *http.Request) {
err := json.NewDecoder(r.Body).Decode(&payload)
if err != nil {
log.Printf("[INFO] Unable to parse payload from API call: %v\n", err)
log.Printf("[INFO] Data received: %#v\n", payload)
tmpltError(w, http.StatusInternalServerError, fmt.Sprintf("Unable to read info from device: %v\n", err))
return
}
log.Printf("[TRACE] Data received: %#v\n", payload)
}