mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-01-07 04:40:05 -06:00
Merge pull request #7851 from owncloud/return200invite
return 200 on successful invite
This commit is contained in:
@@ -494,7 +494,7 @@ func (g Graph) Invite(w http.ResponseWriter, r *http.Request) {
|
||||
case hasErrors && hasSuccesses:
|
||||
render.Status(r, http.StatusMultiStatus)
|
||||
case hasSuccesses:
|
||||
render.Status(r, http.StatusCreated)
|
||||
render.Status(r, http.StatusOK)
|
||||
default:
|
||||
render.Status(r, http.StatusInternalServerError)
|
||||
}
|
||||
|
||||
@@ -322,7 +322,7 @@ var _ = Describe("Driveitems", func() {
|
||||
|
||||
jsonData := gjson.Get(rr.Body.String(), "value")
|
||||
|
||||
Expect(rr.Code).To(Equal(http.StatusCreated))
|
||||
Expect(rr.Code).To(Equal(http.StatusOK))
|
||||
Expect(jsonData.Get("#").Num).To(Equal(float64(2)))
|
||||
|
||||
Expect(jsonData.Get("0.id").Str).To(Equal("123"))
|
||||
@@ -347,7 +347,7 @@ var _ = Describe("Driveitems", func() {
|
||||
|
||||
jsonData := gjson.Get(rr.Body.String(), "value")
|
||||
|
||||
Expect(rr.Code).To(Equal(http.StatusCreated))
|
||||
Expect(rr.Code).To(Equal(http.StatusOK))
|
||||
|
||||
Expect(jsonData.Get(`0.@libre\.graph\.permissions\.actions`).Exists()).To(BeFalse())
|
||||
Expect(jsonData.Get("0.roles.#").Num).To(Equal(float64(1)))
|
||||
@@ -365,7 +365,7 @@ var _ = Describe("Driveitems", func() {
|
||||
|
||||
jsonData := gjson.Get(rr.Body.String(), "value")
|
||||
|
||||
Expect(rr.Code).To(Equal(http.StatusCreated))
|
||||
Expect(rr.Code).To(Equal(http.StatusOK))
|
||||
|
||||
Expect(jsonData.Get("0.roles").Exists()).To(BeFalse())
|
||||
Expect(jsonData.Get(`0.@libre\.graph\.permissions\.actions.#`).Num).To(Equal(float64(1)))
|
||||
|
||||
Reference in New Issue
Block a user