Skip to content

Commit

Permalink
Merge pull request #1 from intraworlds/change_exception_to_throwable
Browse files Browse the repository at this point in the history
main class can catch Throwable, fix it in the main Exception
  • Loading branch information
esler authored Nov 20, 2018
2 parents 9cfae1d + 21ef635 commit 5c7557d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/ServiceContainer/Exception.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
class Exception extends \Exception implements ContainerExceptionInterface
{

public function __construct(string $message = null, \Exception $previous = null) {
public function __construct(string $message = null, \Throwable $previous = null) {
parent::__construct($message, 0, $previous);
}

Expand Down
2 changes: 1 addition & 1 deletion src/ServiceContainer/ServiceNotFoundException.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

class ServiceNotFoundException extends Exception implements NotFoundExceptionInterface
{
public function __construct(string $id, \Exception $previous = null)
public function __construct(string $id, \Throwable $previous = null)
{
parent::__construct('Service object not found, id: ' . $id, $previous);
}
Expand Down

0 comments on commit 5c7557d

Please sign in to comment.