summaryrefslogtreecommitdiff
path: root/lib/util.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/util.php')
-rw-r--r--lib/util.php13
1 files changed, 9 insertions, 4 deletions
diff --git a/lib/util.php b/lib/util.php
index 6c9f6316a..9e8ac26ad 100644
--- a/lib/util.php
+++ b/lib/util.php
@@ -178,7 +178,6 @@ function common_ensure_session()
}
if (isset($id)) {
session_id($id);
- setcookie(session_name(), $id);
}
@session_start();
if (!isset($_SESSION['started'])) {
@@ -990,9 +989,14 @@ function common_enqueue_notice($notice)
static $localTransports = array('omb',
'ping');
- static $allTransports = array('sms', 'plugin');
-
- $transports = $allTransports;
+ $transports = array();
+ if (common_config('sms', 'enabled')) {
+ $transports[] = 'sms';
+ }
+ if (Event::hasHandler('HandleQueuedNotice')) {
+ $transports[] = 'plugin';
+ }
+
$xmpp = common_config('xmpp', 'enabled');
@@ -1000,6 +1004,7 @@ function common_enqueue_notice($notice)
$transports[] = 'jabber';
}
+ // @fixme move these checks into QueueManager and/or individual handlers
if ($notice->is_local == Notice::LOCAL_PUBLIC ||
$notice->is_local == Notice::LOCAL_NONPUBLIC) {
$transports = array_merge($transports, $localTransports);