diff --git a/kiri-engine/Abstracts/Component.php b/kiri-engine/Abstracts/Component.php index 0d20a0ff..3afd6a80 100644 --- a/kiri-engine/Abstracts/Component.php +++ b/kiri-engine/Abstracts/Component.php @@ -231,8 +231,8 @@ class Component implements Configure $context = []; if (is_string($method)) { $message = (empty($method) ? '' : $method . ': ') . $message; - } else { - $context = $method; + } else if (is_object($method)) { + $context = [$method]; } $message = "\033[41;37m" . $message . "\033[0m";