diff --git a/framework/CHANGELOG.md b/framework/CHANGELOG.md index a47c10d50f..03b0aef426 100644 --- a/framework/CHANGELOG.md +++ b/framework/CHANGELOG.md @@ -4,6 +4,7 @@ Yii Framework 2 Change Log 2.0.13 under development ------------------------ +- Bug #14902: Fixed PHP notice in `yii\web\MultipartFormDataParser` (olimsaidov) - Bug #14129: Fixed console help to properly work with tricky camelcased controller names (samdark, silverfire) - Enh #14126: Added variadic parameters support to DI container (SamMousa) - Enh #14087: Added `yii\web\View::registerCsrfMetaTags()` method that registers CSRF tags dynamically ensuring that caching doesn't interfere (RobinKamps) diff --git a/framework/web/MultipartFormDataParser.php b/framework/web/MultipartFormDataParser.php index 67a2eb7e73..0e70ceb86c 100644 --- a/framework/web/MultipartFormDataParser.php +++ b/framework/web/MultipartFormDataParser.php @@ -262,7 +262,8 @@ class MultipartFormDataParser extends BaseObject implements RequestParserInterfa $namePart = trim($namePart, ']'); if ($namePart === '') { $current[] = []; - $lastKey = array_pop(array_keys($current)); + $keys = array_keys($current); + $lastKey = array_pop($keys); $current = &$current[$lastKey]; } else { if (!isset($current[$namePart])) {