mirror of
https://github.com/processone/ejabberd.git
synced 2024-11-24 16:23:40 +01:00
Fix get_queue_length argument type
This commit is contained in:
parent
82296c277a
commit
6c08c53d74
@ -693,11 +693,9 @@ user_queue_parse_query(US, Query) ->
|
|||||||
us_to_list({User, Server}) ->
|
us_to_list({User, Server}) ->
|
||||||
exmpp_jid:to_list(User, Server).
|
exmpp_jid:to_list(User, Server).
|
||||||
|
|
||||||
%% @spec (User::string(), Host::string()) -> integer()
|
%% @spec (User::binary(), Host::binary()) -> integer()
|
||||||
get_queue_length(User, Host) ->
|
get_queue_length(User, Host) ->
|
||||||
UserB = list_to_binary(User),
|
gen_storage:dirty_count_records(Host, offline_msg, [{'=', user_host, {User, Host}}]).
|
||||||
HostB = list_to_binary(Host),
|
|
||||||
gen_storage:dirty_count_records(HostB, offline_msg, [{'=', user_host, {UserB, HostB}}]).
|
|
||||||
|
|
||||||
get_messages_subset(User, Host, MsgsAll) ->
|
get_messages_subset(User, Host, MsgsAll) ->
|
||||||
Access = gen_mod:get_module_opt(Host, ?MODULE, access_max_user_messages,
|
Access = gen_mod:get_module_opt(Host, ?MODULE, access_max_user_messages,
|
||||||
|
@ -1710,7 +1710,7 @@ list_given_users(Host, Users, Prefix, Lang, URLFunc) ->
|
|||||||
get_offlinemsg_length(ModOffline, User, Server) ->
|
get_offlinemsg_length(ModOffline, User, Server) ->
|
||||||
case ModOffline of
|
case ModOffline of
|
||||||
none -> "disabled";
|
none -> "disabled";
|
||||||
_ -> pretty_string_int(ModOffline:get_queue_length(User, Server))
|
_ -> pretty_string_int(ModOffline:get_queue_length(list_to_binary(User), list_to_binary(Server)))
|
||||||
end.
|
end.
|
||||||
|
|
||||||
get_offlinemsg_module(Server) ->
|
get_offlinemsg_module(Server) ->
|
||||||
|
Loading…
Reference in New Issue
Block a user