Skip to content
Snippets Groups Projects
Commit 430e0b01 authored by Diego Sampaio's avatar Diego Sampaio
Browse files

support roomTypes with no permissions

parent 4048ddb6
No related merge requests found
......@@ -33,7 +33,7 @@ RocketChat.roomTypes = new class
getAllTypes = ->
typesPermitted = []
roomTypesOrder.forEach (type) ->
if roomTypes[type].permissions? and RocketChat.authz.hasAtLeastOnePermission roomTypes[type].permissions
if not roomTypes[type].permissions? or RocketChat.authz.hasAtLeastOnePermission roomTypes[type].permissions
typesPermitted.push roomTypes[type]
return typesPermitted
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment