X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;ds=sidebyside;f=bin%2Fauth_ejabberd.php;h=e8a7b4963f629b8b9c31c4ca09c5d5e866776171;hb=a3c1beb265ec91a504ac4ee2ba1343122e6c66ae;hp=901d4a4ceb68bb37873a9bd136ff4ab17ed17743;hpb=334d3921549a538130220f8b627f39f3e0877e26;p=friendica.git diff --git a/bin/auth_ejabberd.php b/bin/auth_ejabberd.php index 901d4a4ceb..e8a7b4963f 100755 --- a/bin/auth_ejabberd.php +++ b/bin/auth_ejabberd.php @@ -33,8 +33,6 @@ */ use Friendica\App; -use Friendica\BaseObject; -use Friendica\Core\Config; use Friendica\Util\ExAuth; if (sizeof($_SERVER["argv"]) == 0) { @@ -51,16 +49,11 @@ $directory = realpath($directory . DIRECTORY_SEPARATOR . ".."); chdir($directory); -require_once "boot.php"; -require_once "include/dba.php"; +require dirname(__DIR__) . '/vendor/autoload.php'; $a = new App(dirname(__DIR__)); -BaseObject::setApp($a); -@include "config/.htconfig.php"; -dba::connect($db_host, $db_user, $db_pass, $db_data); -unset($db_host, $db_user, $db_pass, $db_data); - -$oAuth = new ExAuth(); - -$oAuth->readStdin(); +if ($a->getMode()->isNormal()) { + $oAuth = new ExAuth(); + $oAuth->readStdin(); +}