aboutsummaryrefslogtreecommitdiffstats
path: root/cmd/api/healthcheck.go
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--cmd/api/healthcheck.go4
1 files changed, 1 insertions, 3 deletions
diff --git a/cmd/api/healthcheck.go b/cmd/api/healthcheck.go
index 4c0a8fa..2e7914b 100644
--- a/cmd/api/healthcheck.go
+++ b/cmd/api/healthcheck.go
@@ -14,8 +14,6 @@ func (app *application) healthcheckHandler(w http.ResponseWriter, r *http.Reques
}
err := app.writeJSON(w, http.StatusOK, env, nil)
if err != nil {
- app.logger.Debug("server error", "err", err)
- http.Error(w, "The server encountered a problem and could not process your request", http.StatusInternalServerError)
- return
+ app.serverErrorResponse(w, r, err)
}
}