25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-11-24 16:23:40 +01:00

Fix bug when sorting the list of rooms in WebAdmin

This commit is contained in:
Badlop 2015-04-08 15:34:08 +02:00
parent 32b60d4250
commit f129c6530c

View File

@ -260,7 +260,7 @@ get_sort_query(Q) ->
get_sort_query2(Q) -> get_sort_query2(Q) ->
{value, {_, String}} = lists:keysearch(<<"sort">>, 1, Q), {value, {_, String}} = lists:keysearch(<<"sort">>, 1, Q),
Integer = list_to_integer(String), Integer = list_to_integer(binary_to_list(String)),
case Integer >= 0 of case Integer >= 0 of
true -> {ok, {normal, Integer}}; true -> {ok, {normal, Integer}};
false -> {ok, {reverse, abs(Integer)}} false -> {ok, {reverse, abs(Integer)}}