From 6a088afd4be4076a31e8713ed96ac62060bf7278 Mon Sep 17 00:00:00 2001 From: Evan Prodromou Date: Mon, 21 Sep 2009 14:29:43 -0400 Subject: you can add a daemon to getvaliddaemons --- scripts/getvaliddaemons.php | 29 ++++++++++++++++++++--------- 1 file changed, 20 insertions(+), 9 deletions(-) (limited to 'scripts') diff --git a/scripts/getvaliddaemons.php b/scripts/getvaliddaemons.php index 8f48e8e6f..92edacfd3 100755 --- a/scripts/getvaliddaemons.php +++ b/scripts/getvaliddaemons.php @@ -35,20 +35,31 @@ ENDOFHELP; require_once INSTALLDIR.'/scripts/commandline.inc'; +$daemons = array(); + if(common_config('xmpp','enabled')) { - echo "xmppdaemon.php jabberqueuehandler.php publicqueuehandler.php "; - echo "xmppconfirmhandler.php "; + $daemons[] = 'xmppdaemon.php'; + $daemons[] = 'jabberqueuehandler.php'; + $daemons[] = 'publicqueuehandler.php'; + $daemons[] = 'xmppconfirmhandler.php'; } if(common_config('twitterbridge','enabled')) { - echo "twitterstatusfetcher.php "; + $daemons[] = 'twitterstatusfetcher.php'; } -echo "ombqueuehandler.php "; +$daemons[] = 'ombqueuehandler.php'; if (common_config('twitter', 'enabled')) { - echo "twitterqueuehandler.php "; - echo "synctwitterfriends.php "; + $daemons[] = 'twitterqueuehandler.php'; + $daemons[] = 'synctwitterfriends.php'; } -echo "facebookqueuehandler.php "; -echo "pingqueuehandler.php "; +$daemons[] = 'facebookqueuehandler.php'; +$daemons[] = 'pingqueuehandler.php'; if (common_config('sms', 'enabled')) { - echo "smsqueuehandler.php "; + $daemons[] = 'smsqueuehandler.php'; +} + +if (Event::handle('GetValidDaemons', array(&$daemons))) { + foreach ($daemons as $daemon) { + print $daemon . ' '; + } + print "\n"; } -- cgit v1.2.3-54-g00ecf