Switch static::$parameters to $this->parameters

This commit is contained in:
Philipp
2021-11-14 23:19:25 +01:00
parent 489cd0884a
commit 5879535822
116 changed files with 321 additions and 314 deletions

View File

@@ -30,7 +30,7 @@ class Embed extends BaseAdmin
{
public function init()
{
$theme = Strings::sanitizeFilePathItem(static::$parameters['theme']);
$theme = Strings::sanitizeFilePathItem($this->parameters['theme']);
if (is_file("view/theme/$theme/config.php")) {
DI::app()->setCurrentTheme($theme);
}
@@ -40,7 +40,7 @@ class Embed extends BaseAdmin
{
self::checkAdminAccess();
$theme = Strings::sanitizeFilePathItem(static::$parameters['theme']);
$theme = Strings::sanitizeFilePathItem($this->parameters['theme']);
if (is_file("view/theme/$theme/config.php")) {
require_once "view/theme/$theme/config.php";
if (function_exists('theme_admin_post')) {
@@ -60,7 +60,7 @@ class Embed extends BaseAdmin
{
parent::content();
$theme = Strings::sanitizeFilePathItem(static::$parameters['theme']);
$theme = Strings::sanitizeFilePathItem($this->parameters['theme']);
if (!is_dir("view/theme/$theme")) {
notice(DI::l10n()->t('Unknown theme.'));
return '';