Skip to content

Commit

Permalink
Merge pull request #104 from metal-stack/wrong-firewall-find-http-method
Browse files Browse the repository at this point in the history
Changing firewall find HTTP method to POST.
  • Loading branch information
Gerrit91 authored Sep 21, 2020
2 parents 56d0187 + 118b6ae commit 2a85998
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
5 changes: 3 additions & 2 deletions cmd/metal-api/internal/service/firewall-service.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@ package service

import (
"fmt"
"github.com/metal-stack/metal-api/cmd/metal-api/internal/grpc"
"net/http"

"github.com/metal-stack/metal-api/cmd/metal-api/internal/grpc"

"github.com/metal-stack/metal-lib/httperrors"
"github.com/metal-stack/metal-lib/zapup"
"go.uber.org/zap"
Expand Down Expand Up @@ -76,7 +77,7 @@ func (r firewallResource) webService() *restful.WebService {
Returns(http.StatusOK, "OK", v1.FirewallResponse{}).
DefaultReturns("Error", httperrors.HTTPErrorResponse{}))

ws.Route(ws.GET("/find").
ws.Route(ws.POST("/find").
To(viewer(r.findFirewalls)).
Operation("findFirewalls").
Doc("find firewalls by multiple criteria").
Expand Down
2 changes: 1 addition & 1 deletion spec/metal-api.json
Original file line number Diff line number Diff line change
Expand Up @@ -3053,7 +3053,7 @@
}
},
"/v1/firewall/find": {
"get": {
"post": {
"consumes": [
"application/json"
],
Expand Down

0 comments on commit 2a85998

Please sign in to comment.