From 2042ab090dc4f6206f08260d60bc0bcd8343b836 Mon Sep 17 00:00:00 2001 From: Christophe Romain Date: Mon, 12 Oct 2009 09:06:37 +0000 Subject: [PATCH] Default pubsub messages to headline if nothing is configured (thanks to Brian Cully) (EJAB-1061) SVN Revision: 2655 --- src/mod_pubsub/mod_pubsub.erl | 2 +- src/mod_pubsub/mod_pubsub_odbc.erl | 2 +- src/mod_pubsub/pubsub_odbc.patch | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/mod_pubsub/mod_pubsub.erl b/src/mod_pubsub/mod_pubsub.erl index 9e5f98ade..6b83e9c08 100644 --- a/src/mod_pubsub/mod_pubsub.erl +++ b/src/mod_pubsub/mod_pubsub.erl @@ -3095,7 +3095,7 @@ get_options_for_subs(NodeID, Subs) -> % end broadcast_stanza(Host, Node, _NodeId, _Type, NodeOptions, SubsByDepth, NotifyType, BaseStanza) -> - NotificationType = get_option(NodeOptions, notification_type), + NotificationType = get_option(NodeOptions, notification_type, headline), BroadcastAll = get_option(NodeOptions, broadcast_all_resources), %% XXX this is not standard, but usefull From = service_jid(Host), Stanza = case NotificationType of diff --git a/src/mod_pubsub/mod_pubsub_odbc.erl b/src/mod_pubsub/mod_pubsub_odbc.erl index d8a2ea66f..cbe6b5d75 100644 --- a/src/mod_pubsub/mod_pubsub_odbc.erl +++ b/src/mod_pubsub/mod_pubsub_odbc.erl @@ -2926,7 +2926,7 @@ get_options_for_subs(NodeID, Subs) -> % end broadcast_stanza(Host, Node, _NodeId, _Type, NodeOptions, SubsByDepth, NotifyType, BaseStanza) -> - NotificationType = get_option(NodeOptions, notification_type), + NotificationType = get_option(NodeOptions, notification_type, headline), BroadcastAll = get_option(NodeOptions, broadcast_all_resources), %% XXX this is not standard, but usefull From = service_jid(Host), Stanza = case NotificationType of diff --git a/src/mod_pubsub/pubsub_odbc.patch b/src/mod_pubsub/pubsub_odbc.patch index 49cc8405a..ad1a49153 100644 --- a/src/mod_pubsub/pubsub_odbc.patch +++ b/src/mod_pubsub/pubsub_odbc.patch @@ -1,5 +1,5 @@ ---- mod_pubsub.erl 2009-10-06 17:21:15.000000000 +0200 -+++ mod_pubsub_odbc.erl 2009-10-06 17:21:35.000000000 +0200 +--- mod_pubsub.erl 2009-10-12 11:05:54.000000000 +0200 ++++ mod_pubsub_odbc.erl 2009-10-12 11:06:09.000000000 +0200 @@ -45,7 +45,7 @@ %%% TODO %%% plugin: generate Reply (do not use broadcast atom anymore)