Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion gcore/project/v1/projects/requests.go
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ func Update(c *gcorecloud.ServiceClient, id int, opts UpdateOptsBuilder) (r Upda
r.Err = err
return
}
_, r.Err = c.Put(updateURL(c, id), b, &r.Body, &gcorecloud.RequestOpts{ // nolint
_, r.Err = c.Patch(updateURL(c, id), b, &r.Body, &gcorecloud.RequestOpts{ // nolint
OkCodes: []int{200, 201},
})
return
Expand Down
2 changes: 1 addition & 1 deletion gcore/project/v1/projects/testing/requests_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ func TestUpdate(t *testing.T) {
testURL := prepareGetTestURL(Project1.ID)

th.Mux.HandleFunc(testURL, func(w http.ResponseWriter, r *http.Request) {
th.TestMethod(t, r, "PUT")
th.TestMethod(t, r, "PATCH")
th.TestHeader(t, r, "Authorization", fmt.Sprintf("Bearer %s", fake.AccessToken))
th.TestHeader(t, r, "Content-Type", "application/json")
th.TestHeader(t, r, "Accept", "application/json")
Expand Down
Loading