Skip to content

Commit

Permalink
fix statis and fix path for GET value
Browse files Browse the repository at this point in the history
  • Loading branch information
dieofcode committed Dec 10, 2023
1 parent b8380df commit f987999
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/handler/handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ func (m *Handler) HandleUpdateMetric(w http.ResponseWriter, r *http.Request) {
}

func (m *Handler) HandleGetMetricByName(w http.ResponseWriter, r *http.Request) {
parts := strings.Split(strings.TrimPrefix(r.URL.Path, "/update/"), "/")
parts := strings.Split(strings.TrimPrefix(r.URL.Path, "/value/"), "/")

if len(parts) != 2 {
http.Error(w, "Попытка передать запрос без имени метрики", http.StatusNotFound)
Expand Down

0 comments on commit f987999

Please sign in to comment.