Fixes #14902: Fixed PHP notice in yii\web\MultipartFormDataParser

This commit is contained in:
Olim Saidov
2017-10-04 20:23:58 +05:00
committed by Alexander Makarov
parent 792f50759e
commit b75a85d0da
2 changed files with 3 additions and 1 deletions

View File

@ -4,6 +4,7 @@ Yii Framework 2 Change Log
2.0.13 under development 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) - 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 #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) - Enh #14087: Added `yii\web\View::registerCsrfMetaTags()` method that registers CSRF tags dynamically ensuring that caching doesn't interfere (RobinKamps)

View File

@ -262,7 +262,8 @@ class MultipartFormDataParser extends BaseObject implements RequestParserInterfa
$namePart = trim($namePart, ']'); $namePart = trim($namePart, ']');
if ($namePart === '') { if ($namePart === '') {
$current[] = []; $current[] = [];
$lastKey = array_pop(array_keys($current)); $keys = array_keys($current);
$lastKey = array_pop($keys);
$current = &$current[$lastKey]; $current = &$current[$lastKey];
} else { } else {
if (!isset($current[$namePart])) { if (!isset($current[$namePart])) {