X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FBaseModule.php;h=aaca6c5311e162ea3e6cabb2b79efc3cebbce973;hb=1f79d25ffcef2a740453f0d69f57223c03a50b79;hp=90ba9e13290fe93b0b2ab080ad8ef9dadf51547e;hpb=018275919ce1862e08c9aaf7f8098c610fe71916;p=friendica.git diff --git a/src/BaseModule.php b/src/BaseModule.php index 90ba9e1329..aaca6c5311 100644 --- a/src/BaseModule.php +++ b/src/BaseModule.php @@ -37,32 +37,24 @@ use Friendica\Model\User; abstract class BaseModule implements ICanHandleRequests { /** @var array */ - protected static $parameters = []; + protected $parameters = []; public function __construct(array $parameters = []) { - static::$parameters = $parameters; - } - - /** - * @return array - */ - public static function getParameters(): array - { - return self::$parameters; + $this->parameters = $parameters; } /** * {@inheritDoc} */ - public static function init(array $parameters = []) + public function init() { } /** * {@inheritDoc} */ - public static function rawContent(array $parameters = []) + public function rawContent() { // echo ''; // exit; @@ -71,7 +63,7 @@ abstract class BaseModule implements ICanHandleRequests /** * {@inheritDoc} */ - public static function content(array $parameters = []) + public function content(): string { return ''; } @@ -79,21 +71,21 @@ abstract class BaseModule implements ICanHandleRequests /** * {@inheritDoc} */ - public static function delete(array $parameters = []) + public function delete() { } /** * {@inheritDoc} */ - public static function patch(array $parameters = []) + public function patch() { } /** * {@inheritDoc} */ - public static function post(array $parameters = []) + public function post() { // DI::baseurl()->redirect('module'); } @@ -101,19 +93,12 @@ abstract class BaseModule implements ICanHandleRequests /** * {@inheritDoc} */ - public static function afterpost(array $parameters = []) - { - } - - /** - * {@inheritDoc} - */ - public static function put(array $parameters = []) + public function put() { } /** Gets the name of the current class */ - public static function getClassName(): string + public function getClassName(): string { return static::class; }