aboutsummaryrefslogtreecommitdiff
path: root/src/mod_offline.erl
diff options
context:
space:
mode:
Diffstat (limited to 'src/mod_offline.erl')
-rw-r--r--src/mod_offline.erl5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/mod_offline.erl b/src/mod_offline.erl
index a1bf3da04..4670b9b84 100644
--- a/src/mod_offline.erl
+++ b/src/mod_offline.erl
@@ -830,9 +830,10 @@ webadmin_user_parse_query(Acc, _Action, _User, _Server,
count_offline_messages(LUser, LServer) ->
Username = ejabberd_odbc:escape(LUser),
case catch odbc_queries:count_records_where(
- LServer, "spool", "where username='" ++ Username ++ "'") of
+ LServer, "spool",
+ <<"where username='", Username/binary, "'">>) of
{selected, [_], [{Res}]} ->
- list_to_integer(Res);
+ jlib:binary_to_integer(Res);
_ ->
0
end.