1
0
Fork 0
mirror of https://github.com/processone/ejabberd synced 2025-10-03 09:49:18 +02:00

Raise bad_node instead of node_down for consistency reason

This commit is contained in:
Evgeniy Khramtsov 2017-03-30 17:51:37 +03:00
parent f5f353d90a
commit 3e4ed83cb3
5 changed files with 9 additions and 9 deletions

View file

@ -202,7 +202,7 @@ find_online_room(ServerHost, Room, Host) ->
"name=%(Room)s and host=%(Host)s")) of
{selected, [{PidS, NodeS}]} ->
try {ok, aux:decode_pid(PidS, NodeS)}
catch _:{node_down, _} -> error
catch _:{bad_node, _} -> error
end;
{selected, []} ->
error;
@ -232,7 +232,7 @@ get_online_rooms(ServerHost, Host, _RSM) ->
lists:flatmap(
fun({Room, PidS, NodeS}) ->
try [{Room, Host, aux:decode_pid(PidS, NodeS)}]
catch _:{node_down, _} -> []
catch _:{bad_node, _} -> []
end
end, Rows);
Err ->