diff options
-rw-r--r-- | clientapi/routing/memberships.go | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/clientapi/routing/memberships.go b/clientapi/routing/memberships.go index 513fcefd..6ddcf1be 100644 --- a/clientapi/routing/memberships.go +++ b/clientapi/routing/memberships.go @@ -111,6 +111,9 @@ func GetJoinedRooms( util.GetLogger(req.Context()).WithError(err).Error("QueryRoomsForUser failed") return jsonerror.InternalServerError() } + if res.RoomIDs == nil { + res.RoomIDs = []string{} + } return util.JSONResponse{ Code: http.StatusOK, JSON: getJoinedRoomsResponse{res.RoomIDs}, |