X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=index.php;h=4857b1f12971a20a82c5ae62893bee154b5ebbb7;hb=1e7d9fdcf6fd0e3741a19c5e1bd31b12961c34c1;hp=e8733a82091df1a484f4375b0dd3beb18e76011b;hpb=2c5ba7fc15b96016684f6c9e047144e10e8d7c46;p=friendica.git diff --git a/index.php b/index.php index e8733a8209..4857b1f129 100644 --- a/index.php +++ b/index.php @@ -1,7 +1,22 @@ . + * */ use Dice\Dice; @@ -13,9 +28,16 @@ if (!file_exists(__DIR__ . '/vendor/autoload.php')) { require __DIR__ . '/vendor/autoload.php'; $dice = (new Dice())->addRules(include __DIR__ . '/static/dependencies.config.php'); +$dice = $dice->addRule(Friendica\App\Mode::class, ['call' => [['determineRunMode', [false, $_SERVER], Dice::CHAIN_CALL]]]); -\Friendica\BaseObject::setDependencyInjection($dice); +\Friendica\DI::init($dice); -$a = \Friendica\BaseObject::getApp(); +$a = \Friendica\DI::app(); -$a->runFrontend($dice->create(\Friendica\App\Module::class), $dice->create(\Friendica\App\Router::class), $dice->create(\Friendica\Core\Config\PConfiguration::class)); +$a->runFrontend( + $dice->create(\Friendica\App\Module::class), + $dice->create(\Friendica\App\Router::class), + $dice->create(\Friendica\Core\PConfig\IPConfig::class), + $dice->create(\Friendica\App\Authentication::class), + $dice->create(\Friendica\App\Page::class) +);