From: Jean Baptiste Favre Date: Sun, 26 Aug 2012 21:20:03 +0000 (+0200) Subject: Add configuration check. Need 'server', 'port', 'user' and 'password' to be defined... X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=1b39f89b964feee673961e5bdff2266b8716f96e;p=quix0rs-gnu-social.git Add configuration check. Need 'server', 'port', 'user' and 'password' to be defined (not valid, just defined). --- diff --git a/plugins/Xmpp/XmppPlugin.php b/plugins/Xmpp/XmppPlugin.php index b21afab461..74e104d974 100644 --- a/plugins/Xmpp/XmppPlugin.php +++ b/plugins/Xmpp/XmppPlugin.php @@ -442,11 +442,17 @@ class XmppPlugin extends ImPlugin */ function onGetValidDaemons($daemons) { - array_push( - $daemons, - INSTALLDIR - . '/scripts/imdaemon.php' - ); + if( isset($this->server) && + isset($this->port) && + isset($this->user) && + isset($this->password) ){ + + array_push( + $daemons, + INSTALLDIR + . '/scripts/imdaemon.php' + ); + } return true; }