fix: bulky error message for invalid search request (#8444)

This commit is contained in:
Sawjan Gurung authored and GitHub committed 2024-02-13 15:58:26 +05:45
1 parent 84dc519d10
commit 911754fd42
2 files changed
+7 -1

No files matched your search

@@ -0,0 +1,6 @@
Bugfix: Fix search error message
We fixed an error message returned when the search request is invalid
https://github.com/owncloud/ocis/pull/8444
https://github.com/owncloud/ocis/issues/8442
+1 -1
View File
@@ -78,7 +78,7 @@ func (g Webdav) Search(w http.ResponseWriter, r *http.Request) {
e := merrors.Parse(err.Error())
switch e.Code {
case http.StatusBadRequest:
renderError(w, r, errBadRequest(err.Error()))
renderError(w, r, errBadRequest(e.Detail))
default:
renderError(w, r, errInternalError(err.Error()))
}