diff options
author | Robin Millette <millette@controlyourself.ca> | 2009-04-24 20:01:25 +0000 |
---|---|---|
committer | Robin Millette <millette@controlyourself.ca> | 2009-04-24 20:01:25 +0000 |
commit | f2f4e8c5868ef7fee694590c17bacec4e01e3b9b (patch) | |
tree | 78df1002c3cfc902e5b16cbe858e3efa675a2f14 /lib/util.php | |
parent | c008c0d4a56ec265ba6e10d208f9954510296f12 (diff) | |
parent | 5e7664e25f6c4b93d32bc1ef33463c09205ff679 (diff) |
Merge branch '0.7.x' of git@gitorious.org:laconica/dev into 0.7.x
Diffstat (limited to 'lib/util.php')
-rw-r--r-- | lib/util.php | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/lib/util.php b/lib/util.php index e1dd238ba..f862d7fcc 100644 --- a/lib/util.php +++ b/lib/util.php @@ -879,7 +879,23 @@ function common_broadcast_notice($notice, $remote=false) function common_enqueue_notice($notice) { - foreach (array('jabber', 'omb', 'sms', 'public', 'twitter', 'facebook', 'ping') as $transport) { + $transports = array('omb', 'sms', 'twitter', 'facebook', 'ping'); + + if (common_config('xmpp', 'enabled')) { + $transports = array_merge($transports, array('jabber', 'public')); + } + + if (common_config('memcached', 'enabled')) { + // Note: limited to 8 chars + $transports[] = 'memcache'; + } + + if (common_config('inboxes', 'enabled') === true || + common_config('inboxes', 'enabled') === 'transitional') { + $transports[] = 'inbox'; + } + + foreach ($transports as $transport) { $qi = new Queue_item(); $qi->notice_id = $notice->id; $qi->transport = $transport; @@ -1332,7 +1348,7 @@ function common_compatible_license($from, $to) */ function common_database_tablename($tablename) { - + if(common_config('db','quote_identifiers')) { $tablename = '"'. $tablename .'"'; } |