mirror of
https://github.com/processone/ejabberd.git
synced 2024-11-22 16:20:52 +01:00
fix empty pubsub payload check
This commit is contained in:
parent
fd52f2cb7d
commit
c3a88c713b
@ -2025,7 +2025,7 @@ publish_item(Host, ServerHost, Node, Publisher, ItemId, Payload) ->
|
|||||||
DeliverPayloads = get_option(Options, deliver_payloads),
|
DeliverPayloads = get_option(Options, deliver_payloads),
|
||||||
PersistItems = get_option(Options, persist_items),
|
PersistItems = get_option(Options, persist_items),
|
||||||
PayloadCount = payload_xmlelements(Payload),
|
PayloadCount = payload_xmlelements(Payload),
|
||||||
PayloadSize = size(term_to_binary(Payload)),
|
PayloadSize = size(term_to_binary(Payload))-2, % size(term_to_binary([])) == 2
|
||||||
PayloadMaxSize = get_option(Options, max_payload_size),
|
PayloadMaxSize = get_option(Options, max_payload_size),
|
||||||
% pubsub#deliver_payloads true
|
% pubsub#deliver_payloads true
|
||||||
% pubsub#persist_items true -> 1 item; false -> 0 item
|
% pubsub#persist_items true -> 1 item; false -> 0 item
|
||||||
|
Loading…
Reference in New Issue
Block a user