mirror of
https://github.com/processone/ejabberd.git
synced 2024-06-18 22:15:20 +02:00
Use muc_online_room record for pattern matching
This commit is contained in:
parent
c0da9b43ce
commit
583476380a
|
@ -178,7 +178,8 @@ muc_online_rooms(ServerHost) ->
|
||||||
MUCHost = find_host(ServerHost),
|
MUCHost = find_host(ServerHost),
|
||||||
Rooms = ets:tab2list(muc_online_room),
|
Rooms = ets:tab2list(muc_online_room),
|
||||||
lists:foldl(
|
lists:foldl(
|
||||||
fun({_, {Roomname, Host}, _}, Results) ->
|
fun(Room, Results) ->
|
||||||
|
{Roomname, Host} = Room#muc_online_room.name_host,
|
||||||
case MUCHost of
|
case MUCHost of
|
||||||
global ->
|
global ->
|
||||||
[<<Roomname/binary, "@", Host/binary>> | Results];
|
[<<Roomname/binary, "@", Host/binary>> | Results];
|
||||||
|
|
Loading…
Reference in New Issue
Block a user