mirror of
https://github.com/Piwigo/Piwigo.git
synced 2025-04-27 03:39:57 +03:00
Correction for PHP Deprecated: explode()
More robust syntax if $_GET['section'] turns out to be null, avoid messages as PHP Deprecated: explode(): Passing null to parameter #2 ($string) of type string is deprecated
This commit is contained in:
parent
d69bc8b884
commit
75392e6886
1 changed files with 2 additions and 2 deletions
|
@ -14,7 +14,7 @@ if( !defined("PHPWG_ROOT_PATH") )
|
||||||
include_once(PHPWG_ROOT_PATH.'admin/include/functions.php');
|
include_once(PHPWG_ROOT_PATH.'admin/include/functions.php');
|
||||||
check_status(ACCESS_ADMINISTRATOR);
|
check_status(ACCESS_ADMINISTRATOR);
|
||||||
|
|
||||||
$sections = explode('/', $_GET['section'] );
|
$sections = explode('/', $_GET['section'] ?? '');
|
||||||
for ($i=0; $i<count($sections); $i++)
|
for ($i=0; $i<count($sections); $i++)
|
||||||
{
|
{
|
||||||
if (empty($sections[$i]))
|
if (empty($sections[$i]))
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue