src/log/LogstashTarget.php
private function parseText ($text)
		{
			$type = gettype($text);
			switch ($type)
			{
				case 'array':
					return $text;
				case 'string':
					return [ '@message' => $text ];
				case 'object':
					return get_object_vars($text);
				default:
					return [ '@message' => \Yii::t('log', "Warning, wrong log message type '{$type}'") ];
			}
		}
private function parseText ($text)
		{
			$type = gettype($text);
			switch ($type)
			{
				case 'array':
					return $text;
				case 'string':
					return [ '@message' => $text ];
				case 'object':
					return get_object_vars($text);
				default:
					return [ '@message' => \Yii::t('log', "Warning, wrong log message type '{$type}'") ];
			}
		}
private function parseText ( $ text ) { $ type = gettype ( $ text ) ; switch ( $ type ) { case 'array' : return $ text ; case 'string' : return [ '@message' => $ text ] ; case 'object' : return get_object_vars ( $ text ) ; default : return [ '@message' => \ Yii :: t ( 'log' , "Warning, wrong log message type '{$type}'" ) ] ; } }
Convert's any type of log message to array.

@param mixed $text Input log message.

@return array
Convert s any type of log message to array .