feat(spot): added getStatus request to public key whitelist

This commit is contained in:
Alexander 2024-09-03 11:10:25 +02:00
parent 81238bb0a1
commit e4555cf7af

View file

@ -147,7 +147,10 @@ func isSpotWithKeyRequest(r *http.Request) bool {
}
getSpotPrefix := "/v1/spots/{id}" // GET
addCommentPrefix := "/v1/spots/{id}/comment" // POST
if (pathTemplate == getSpotPrefix && r.Method == "GET") || (pathTemplate == addCommentPrefix && r.Method == "POST") {
getStatusPrefix := "/v1/spots/{id}/status" // GET
if (pathTemplate == getSpotPrefix && r.Method == "GET") ||
(pathTemplate == addCommentPrefix && r.Method == "POST") ||
(pathTemplate == getStatusPrefix && r.Method == "GET") {
return true
}
return false