From 566ff41b6b802c60b0bd6dd79d6c4f0f00f1c8d1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Toma=C5=BE=20Jerman?= Date: Fri, 1 Mar 2024 13:18:54 +0100 Subject: [PATCH] Temporary fix for user listing via compose user field --- server/system/rest/user.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/server/system/rest/user.go b/server/system/rest/user.go index a9ad0f34a7..2c0c40e4bb 100644 --- a/server/system/rest/user.go +++ b/server/system/rest/user.go @@ -110,6 +110,11 @@ func (ctrl User) List(ctx context.Context, r *request.UserList) (interface{}, er } ) + // @todo improve this either on the request parsing stage or query building stage + if len(f.UserID) == 1 && f.UserID[0] == "" { + f.UserID = nil + } + if f.Paging, err = filter.NewPaging(r.Limit, r.PageCursor); err != nil { return nil, err }