Permalink
Browse files

Fix crash when user publishes an item (EJAB-1457)

  • Loading branch information...
1 parent 7248ee1 commit 9c9f278a96d63e34de1bfc9a54f80a4537922b0f @badlop badlop committed Jun 1, 2011
Showing with 2 additions and 2 deletions.
  1. +2 −2 src/mod_pubsub/mod_pubsub.erl
@@ -2420,8 +2420,8 @@ publish_item(Host, ServerHost, Node, Publisher, ItemId, Payload) ->
DeliverPayloads = get_option(Options, deliver_payloads),
PersistItems = get_option(Options, persist_items),
MaxItems = case PersistItems of
- 0 -> 0;
- 1 -> max_items(Host, Options)
+ false -> 0;
+ true -> max_items(Host, Options)
end,
{PayloadCount, PayloadNS} = payload_els_ns(Payload),
PayloadSize = size(term_to_binary(Payload))-2, % size(term_to_binary([])) == 2

0 comments on commit 9c9f278

Please sign in to comment.