mirror of
https://github.com/optim-enterprises-bv/vault.git
synced 2025-11-01 11:08:10 +00:00
Replace http method strings with net/http constants (#14677)
This commit is contained in:
committed by
GitHub
parent
7f36a29e04
commit
0dd4cda7c9
@@ -1,6 +1,9 @@
|
||||
package api
|
||||
|
||||
import "context"
|
||||
import (
|
||||
"context"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
func (c *Sys) StepDown() error {
|
||||
return c.StepDownWithContext(context.Background())
|
||||
@@ -10,7 +13,7 @@ func (c *Sys) StepDownWithContext(ctx context.Context) error {
|
||||
ctx, cancelFunc := c.c.withConfiguredTimeout(ctx)
|
||||
defer cancelFunc()
|
||||
|
||||
r := c.c.NewRequest("PUT", "/v1/sys/step-down")
|
||||
r := c.c.NewRequest(http.MethodPut, "/v1/sys/step-down")
|
||||
|
||||
resp, err := c.c.rawRequestWithContext(ctx, r)
|
||||
if resp != nil && resp.Body != nil {
|
||||
|
||||
Reference in New Issue
Block a user