Send 404 on UUID route when not found
This commit is contained in:
1 parent
e2b591c84f
commit
2c0b39c2d2
1 file changed
+7
@@ -22,5 +22,12 @@ func UUIDHandler(ctx *fasthttp.RequestCtx) {
|
||||
return
|
||||
}
|
||||
|
||||
if len(uuid) < 1 {
|
||||
ctx.SetStatusCode(404)
|
||||
ctx.SetBodyString(http.StatusText(http.StatusNotFound))
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
ctx.SetBodyString(uuid)
|
||||
}
|
||||
Reference in new issue
Block a user