1
0
Fork 0

Added exception class and message to the error string.

pull/699/head
Andrea Turso 2012-05-15 21:47:17 +01:00
parent f626ccbcee
commit f8b2f203a1
1 changed files with 5 additions and 1 deletions

View File

@ -94,7 +94,11 @@ class EventDispatcher
try {
$className::$methodName($event);
} catch (\Exception $e) {
throw new \RuntimeException("'{$callable}' terminated with an exception.");
$message = "%s terminated with an exception.\n[%s] %s";
throw new \RuntimeException(sprintf($message,
$callable,
get_class($e),
$e->getMessage()));
}
}
}