Skip to content
Permalink
Browse files

Helpers::improveException() handles error 'Call to undefined method p…

…arent::xxx()'
  • Loading branch information...
dg committed Mar 9, 2019
1 parent e7ae816 commit 155e31030ebf44a55b9000f32d073d190b71f5ad
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/Tracy/Helpers.php
@@ -184,7 +184,7 @@ public static function improveException(\Throwable $e): void
$replace = ["$m[2](", "$hint("];
} elseif (preg_match('#^Call to undefined method ([\w\\\\]+)::(\w+)#', $message, $m)) {
$hint = self::getSuggestion(get_class_methods($m[1]), $m[2]);
$hint = self::getSuggestion(get_class_methods($m[1]) ?: [], $m[2]);
$message .= ", did you mean $hint()?";
$replace = ["$m[2](", "$hint("];

0 comments on commit 155e310

Please sign in to comment.
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.