mirror of
https://git.sekbaer.de/Friendica/friendica.git
synced 2025-06-07 15:54:26 +02:00
Move adding Dice rules into App
This commit is contained in:
parent
19cd11cc8e
commit
856f8fb908
2 changed files with 14 additions and 8 deletions
|
@ -18,14 +18,6 @@ require __DIR__ . '/vendor/autoload.php';
|
|||
$request = \GuzzleHttp\Psr7\ServerRequest::fromGlobals();
|
||||
|
||||
$dice = (new Dice())->addRules(include __DIR__ . '/static/dependencies.config.php');
|
||||
/** @var \Friendica\Core\Addon\Capability\ICanLoadAddons $addonLoader */
|
||||
$addonLoader = $dice->create(\Friendica\Core\Addon\Capability\ICanLoadAddons::class);
|
||||
$dice = $dice->addRules($addonLoader->getActiveAddonConfig('dependencies'));
|
||||
$dice = $dice->addRule(Friendica\App\Mode::class, ['call' => [['determineRunMode', [false, $request->getServerParams()], Dice::CHAIN_CALL]]]);
|
||||
|
||||
\Friendica\DI::init($dice);
|
||||
|
||||
\Friendica\Core\Logger\Handler\ErrorHandler::register($dice->create(\Psr\Log\LoggerInterface::class));
|
||||
|
||||
$a = \Friendica\App::fromDice($dice);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue