]> git.mxchange.org Git - friendica.git/commitdiff
Apply suggestions from code review
authorPhilipp <admin+Github@philipp.info>
Mon, 17 Jul 2023 18:20:21 +0000 (20:20 +0200)
committerGitHub <noreply@github.com>
Mon, 17 Jul 2023 18:20:21 +0000 (20:20 +0200)
Co-authored-by: Hypolite Petovan <hypolite@mrpetovan.com>
bin/daemon.php
bin/worker.php
src/Core/Addon/Exception/AddonInvalidConfigFileException.php
src/Core/Hooks/Exceptions/HookConfigException.php
src/Core/Logger/Exception/LogLevelException.php
src/Core/Logger/Exception/LoggerArgumentException.php
src/Core/Logger/Exception/LoggerException.php
src/Core/Logger/Exception/LoggerUnusableException.php
src/Core/Logger/Factory/AbstractLoggerTypeFactory.php

index 317798a1ddca347c93a15a710ff603701fe6c73d..11bad2b11a9b43b10106c56a093a185985b52b33 100755 (executable)
@@ -63,7 +63,7 @@ $dice = (new Dice())->addRules(include __DIR__ . '/../static/dependencies.config
 /** @var \Friendica\Core\Addon\Capabilities\ICanLoadAddons $addonLoader */
 $addonLoader = $dice->create(\Friendica\Core\Addon\Capabilities\ICanLoadAddons::class);
 $dice = $dice->addRules($addonLoader->getActiveAddonConfig('dependencies'));
-$dice = $dice->addRule(LoggerInterface::class,['constructParams' => [Logger\Capabilities\LogChannel::DAEMON]]);
+$dice = $dice->addRule(LoggerInterface::class, ['constructParams' => [Logger\Capabilities\LogChannel::DAEMON]]);
 
 DI::init($dice);
 \Friendica\Core\Logger\Handler\ErrorHandler::register($dice->create(\Psr\Log\LoggerInterface::class));
index 18a41e06436fab83fdc78fca66ddf64c0c438984..42a8f533d3771a9480b83a30d2c8b0ac56b8aead 100755 (executable)
@@ -58,7 +58,7 @@ $dice = (new Dice())->addRules(include __DIR__ . '/../static/dependencies.config
 /** @var \Friendica\Core\Addon\Capabilities\ICanLoadAddons $addonLoader */
 $addonLoader = $dice->create(\Friendica\Core\Addon\Capabilities\ICanLoadAddons::class);
 $dice = $dice->addRules($addonLoader->getActiveAddonConfig('dependencies'));
-$dice = $dice->addRule(LoggerInterface::class,['constructParams' => [LogChannel::WORKER]]);
+$dice = $dice->addRule(LoggerInterface::class, ['constructParams' => [LogChannel::WORKER]]);
 
 DI::init($dice);
 \Friendica\Core\Logger\Handler\ErrorHandler::register($dice->create(\Psr\Log\LoggerInterface::class));
index 3bb41be53cde1bf84c81469a103ca46c45b86788..bf173d0a4b17cb7fe8b0a511ddc149288bb28543 100644 (file)
@@ -28,7 +28,7 @@ use Throwable;
  */
 class AddonInvalidConfigFileException extends \RuntimeException
 {
-       public function __construct($message = "", $code = 0, Throwable $previous = null)
+       public function __construct($message = '', $code = 0, Throwable $previous = null)
        {
                parent::__construct($message, 500, $previous);
        }
index ceca721b1d96a77e6d15a66d76cd7c044937a57d..6588787eba9d459892a81881f811bcd624a00aa2 100644 (file)
@@ -23,7 +23,7 @@ namespace Friendica\Core\Hooks\Exceptions;
 
 class HookConfigException extends \RuntimeException
 {
-       public function __construct($message = "", \Throwable $previous = null)
+       public function __construct($message = '', \Throwable $previous = null)
        {
                parent::__construct($message, 500, $previous);
        }
index a79db80f54a3a7a39a3d025e1e3d75dd7169df4a..9cf649a863c11be57cd6b0f64dae40a62650be14 100644 (file)
@@ -28,7 +28,7 @@ use Throwable;
  */
 class LogLevelException extends \InvalidArgumentException
 {
-       public function __construct($message = "", Throwable $previous = null)
+       public function __construct($message = '', Throwable $previous = null)
        {
                parent::__construct($message, 500, $previous);
        }
index bbc1fc0666141005320f2f5370863217261bcb4d..6925be4c7d42a6498929d6f01e0ed70743d9964d 100644 (file)
@@ -28,7 +28,7 @@ use Throwable;
  */
 class LoggerArgumentException extends \InvalidArgumentException
 {
-       public function __construct($message = "", Throwable $previous = null)
+       public function __construct($message = '', Throwable $previous = null)
        {
                parent::__construct($message, 500, $previous);
        }
index 7425576786f73ce8e382896ca2b6d678b0cf589a..7529f6e78bf35d5c11c007f872a9892147de115f 100644 (file)
@@ -28,7 +28,7 @@ use Throwable;
  */
 class LoggerException extends \Exception
 {
-       public function __construct($message = "", Throwable $previous = null)
+       public function __construct($message = '', Throwable $previous = null)
        {
                parent::__construct($message, 500, $previous);
        }
index 46e49fd414c95a42bbdfbf66e00c9fa3b3022455..401a634825562f7f5f93acb463e9744379f74661 100644 (file)
@@ -28,7 +28,7 @@ use Throwable;
  */
 class LoggerUnusableException extends \RuntimeException
 {
-       public function __construct($message = "", Throwable $previous = null)
+       public function __construct($message = '', Throwable $previous = null)
        {
                parent::__construct($message, 500, $previous);
        }
index a6ff5eebbcee9aefa1ffc597fa2650d54df6dbab..402176d8e65ba1961e8598f79aeadfc961de45c4 100644 (file)
@@ -69,7 +69,7 @@ abstract class AbstractLoggerTypeFactory
                                return LogLevel::INFO;
                        // legacy DATA
                        case "4":
-                               // legacy ALL
+                       // legacy ALL
                        case "5":
                                return LogLevel::DEBUG;
                        // default if nothing set