\Yii::$app->getLog()->log("$language message from category $category is invalid. Message is: $message.",Logger::LEVEL_WARNING,'application');
Yii::warning("$language message from category $category is invalid. Message is: $message.");
}else{
return$message;
}
$result=$formatter->format($params);
$result=$formatter->format($params);
if($result===false){
if($result===false){
$errorMessage=$formatter->getErrorMessage();
$errorMessage=$formatter->getErrorMessage();
\Yii::$app->getLog()->log("$language message from category $category failed with error: $errorMessage. Message is: $message.",Logger::LEVEL_WARNING,'application');
Yii::warning("$language message from category $category failed with error: $errorMessage. Message is: $message.");