From e2afed3a8b63d4559812d1923a700513330972aa Mon Sep 17 00:00:00 2001 From: Saumit Dinesan Date: Tue, 28 Nov 2023 22:40:04 +0530 Subject: handlers - adding log for ID not Found error --- handlers/handlers.go | 1 + 1 file changed, 1 insertion(+) (limited to 'handlers/handlers.go') diff --git a/handlers/handlers.go b/handlers/handlers.go index 62b9ac0..1505f08 100644 --- a/handlers/handlers.go +++ b/handlers/handlers.go @@ -107,6 +107,7 @@ func VerifyHash(c echo.Context) error { err = db.QueryRow("SELECT HashValue FROM hashes WHERE ID = ?", id).Scan(&storedHash) if err != nil { if err == sql.ErrNoRows { + log.Println("ID not Found") return c.JSON(http.StatusNotFound, map[string]string{"message": "2"}) } log.Println("Failed to query database:", err) -- cgit v1.2.3