mirror of
https://github.com/yiisoft/yii.git
synced 2026-02-20 01:21:22 +01:00
PHP 8 compatibility: Fix passing null to string parameter parameter
This commit is contained in:
@@ -229,6 +229,9 @@ abstract class CConsoleCommand extends CComponent
|
||||
$params=array(); // unnamed parameters
|
||||
foreach($args as $arg)
|
||||
{
|
||||
if (is_null($arg))
|
||||
continue;
|
||||
|
||||
if(preg_match('/^--(\w+)(=(.*))?$/',$arg,$matches)) // an option
|
||||
{
|
||||
$name=$matches[1];
|
||||
|
||||
Reference in New Issue
Block a user