1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-08-11 19:24:01 +02:00

[ticket/16736] Fix static declarations on master

PHPBB3-16736
This commit is contained in:
Máté Bartus
2021-03-24 01:22:27 +01:00
parent 46d2a93ae6
commit 4737da3ec7
8 changed files with 24 additions and 24 deletions

View File

@@ -20,7 +20,7 @@ class helper
/**
* @var symfony_filesystem
*/
protected static $symfony_filesystem;
static protected $symfony_filesystem;
/**
* Eliminates useless . and .. components from specified path.
@@ -29,7 +29,7 @@ class helper
*
* @return string Cleaned path
*/
public static function clean_path($path)
static public function clean_path($path)
{
$exploded = explode('/', $path);
$filtered = array();
@@ -60,7 +60,7 @@ class helper
*
* @return bool true if the path is absolute, false otherwise
*/
public static function is_absolute_path($path)
static public function is_absolute_path($path)
{
return (isset($path[0]) && $path[0] === '/' || preg_match('#^[a-z]:[/\\\]#i', $path)) ? true : false;
}
@@ -71,7 +71,7 @@ class helper
* @param string $path
* @return bool|string
*/
protected static function phpbb_own_realpath($path)
static protected function phpbb_own_realpath($path)
{
// Replace all directory separators with '/'
$path = str_replace(DIRECTORY_SEPARATOR, '/', $path);
@@ -177,7 +177,7 @@ class helper
*
* @return string Resolved path
*/
public static function realpath($path)
static public function realpath($path)
{
if (!function_exists('realpath'))
{
@@ -210,7 +210,7 @@ class helper
*
* @return string Path of target relative to starting path
*/
public static function make_path_relative($end_path, $start_path)
static public function make_path_relative($end_path, $start_path)
{
// Ensure paths are absolute as passing relative paths to the
// Symsony's Filesystem::makePathRelative() method is removed since Symfony 4.0
@@ -238,7 +238,7 @@ class helper
* @return string|array|bool returns the resolved path or an array of parts of the path if $return_array is true
* or false if path cannot be resolved
*/
public static function resolve_path($path, $prefix = '', $absolute = false, $return_array = false)
static public function resolve_path($path, $prefix = '', $absolute = false, $return_array = false)
{
if ($return_array)
{
@@ -385,7 +385,7 @@ class helper
*
* @return symfony_filesystem Symfony filesystem
*/
protected static function get_symfony_filesystem()
static protected function get_symfony_filesystem()
{
if (self::$symfony_filesystem === null)
{