mirror of
https://github.com/yiisoft/yii2.git
synced 2025-11-24 18:51:27 +08:00
Fixed yii\console\controllers\MessageController handles category name containing dot incorrectly
This commit is contained in:
@@ -91,6 +91,7 @@ Yii Framework 2 Change Log
|
||||
- Bug #4880: Return value of yii\web\Request::getPrefferedLanguage() was a normalized value instead of a valid language value from the input array (cebe)
|
||||
- Bug #4905: ActiveForm::$validationDelay doesn't delay after keyrelease when $validateOnType=true (qiangxue)
|
||||
- Bug #4920: `yii\filters\auth\CompositeAuth` should not trigger error as long as one of the methods succeeds (qiangxue)
|
||||
- Bug #4926: Fixed `yii\console\controllers\MessageController` handles category name containing dot incorrectly (klimov-paul)
|
||||
- Bug #4938: When `yii\db\ActiveQuery` is used to build sub-queries, its WHERE clause is not correctly generated (qiangxue)
|
||||
- Bug #4954: MSSQL column comments are not retrieved correctly (SerjRamone)
|
||||
- Bug #4970: `joinWith()` called by a relation was ignored by `yii\db\ActiveQuery` (stepanselyuk)
|
||||
|
||||
@@ -260,13 +260,9 @@ class MessageController extends Controller
|
||||
PREG_SET_ORDER
|
||||
);
|
||||
for ($i = 0; $i < $n; ++$i) {
|
||||
if (($pos = strpos($matches[$i][1], '.')) !== false) {
|
||||
$category = substr($matches[$i][1], $pos + 1, -1);
|
||||
} else {
|
||||
$category = substr($matches[$i][1], 1, -1);
|
||||
}
|
||||
$category = substr($matches[$i][1], 1, -1);
|
||||
$message = $matches[$i][2];
|
||||
$messages[$category][] = eval("return $message;"); // use eval to eliminate quote escape
|
||||
$messages[$category][] = eval("return {$message};"); // use eval to eliminate quote escape
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user