mirror of
https://github.com/friendica/friendica
synced 2025-04-26 17:10:10 +00:00
Replace $parameters
argument per method with static::$parameters
This commit is contained in:
parent
018275919c
commit
714f0febc4
249 changed files with 710 additions and 775 deletions
|
@ -30,11 +30,11 @@ use Friendica\Util\Strings;
|
|||
|
||||
class Details extends BaseAdmin
|
||||
{
|
||||
public static function content(array $parameters = [])
|
||||
public static function content()
|
||||
{
|
||||
parent::content($parameters);
|
||||
parent::content();
|
||||
|
||||
$theme = Strings::sanitizeFilePathItem($parameters['theme']);
|
||||
$theme = Strings::sanitizeFilePathItem(static::$parameters['theme']);
|
||||
if (!is_dir("view/theme/$theme")) {
|
||||
notice(DI::l10n()->t("Item not found."));
|
||||
return '';
|
||||
|
|
|
@ -28,19 +28,19 @@ use Friendica\Util\Strings;
|
|||
|
||||
class Embed extends BaseAdmin
|
||||
{
|
||||
public static function init(array $parameters = [])
|
||||
public static function init()
|
||||
{
|
||||
$theme = Strings::sanitizeFilePathItem($parameters['theme']);
|
||||
$theme = Strings::sanitizeFilePathItem(static::$parameters['theme']);
|
||||
if (is_file("view/theme/$theme/config.php")) {
|
||||
DI::app()->setCurrentTheme($theme);
|
||||
}
|
||||
}
|
||||
|
||||
public static function post(array $parameters = [])
|
||||
public static function post()
|
||||
{
|
||||
self::checkAdminAccess();
|
||||
|
||||
$theme = Strings::sanitizeFilePathItem($parameters['theme']);
|
||||
$theme = Strings::sanitizeFilePathItem(static::$parameters['theme']);
|
||||
if (is_file("view/theme/$theme/config.php")) {
|
||||
require_once "view/theme/$theme/config.php";
|
||||
if (function_exists('theme_admin_post')) {
|
||||
|
@ -56,11 +56,11 @@ class Embed extends BaseAdmin
|
|||
DI::baseUrl()->redirect('admin/themes/' . $theme . '/embed?mode=minimal');
|
||||
}
|
||||
|
||||
public static function content(array $parameters = [])
|
||||
public static function content()
|
||||
{
|
||||
parent::content($parameters);
|
||||
parent::content();
|
||||
|
||||
$theme = Strings::sanitizeFilePathItem($parameters['theme']);
|
||||
$theme = Strings::sanitizeFilePathItem(static::$parameters['theme']);
|
||||
if (!is_dir("view/theme/$theme")) {
|
||||
notice(DI::l10n()->t('Unknown theme.'));
|
||||
return '';
|
||||
|
|
|
@ -29,9 +29,9 @@ use Friendica\Util\Strings;
|
|||
|
||||
class Index extends BaseAdmin
|
||||
{
|
||||
public static function content(array $parameters = [])
|
||||
public static function content()
|
||||
{
|
||||
parent::content($parameters);
|
||||
parent::content();
|
||||
|
||||
$allowed_themes = Theme::getAllowedList();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue