Skip to content

Commit 9635c6d

Browse files
authored
Merge pull request #4865 from 2403905/fix-appnew-brake
Permission denied is now backing the request.
2 parents 21f62e9 + 3792d96 commit 9635c6d

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
Bugfix: Better response codes for app new endpoint
2+
3+
We fixed the response codes for the app new endpoint. Permission denied is now backing the request.
4+
5+
https://github.com/cs3org/reva/pull/4865

internal/http/services/appprovider/appprovider.go

+1
Original file line numberDiff line numberDiff line change
@@ -254,6 +254,7 @@ func (s *svc) handleNew(w http.ResponseWriter, r *http.Request) {
254254
switch createRes.Status.Code {
255255
case rpc.Code_CODE_PERMISSION_DENIED:
256256
writeError(w, r, appErrorPermissionDenied, "permission denied to create the file", nil)
257+
return
257258
case rpc.Code_CODE_NOT_FOUND:
258259
writeError(w, r, appErrorNotFound, "parent container does not exist", nil)
259260
return

0 commit comments

Comments
 (0)