Skip to content

Commit 0de46c9

Browse files
committed
updates error handling.
1 parent 8f7a79a commit 0de46c9

File tree

3 files changed

+5
-4
lines changed

3 files changed

+5
-4
lines changed

src/Bootstrap.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ function boot( string $ConfigPath ) : Application
3838
{
3939
$App = new Application( $Version->getAsString(), $Settings );
4040
}
41-
catch( \Exception $e )
41+
catch( \Throwable $e )
4242
{
4343
echo Application::beautifyException( $e );
4444
exit( 1 );
@@ -80,7 +80,7 @@ function dispatch( Application $App ) : void
8080
]
8181
);
8282
}
83-
catch( \Exception $e )
83+
catch( \Throwable $e )
8484
{
8585
echo $App->handleException( $e );
8686
}

src/Mvc/Application.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -483,7 +483,7 @@ public function clearExpiredCache(): int
483483
return 0;
484484
}
485485

486-
public static function beautifyException( \Exception $e ): string
486+
public function beautifyException( \Throwable $e ): string
487487
{
488488
// this function should return a nicely formatted HTML representation of the exception
489489
$ExceptionType = get_class( $e );
@@ -508,7 +508,7 @@ public static function beautifyException( \Exception $e ): string
508508
return $Html;
509509
}
510510

511-
public function handleException( \Exception $e ) : string
511+
public function handleException( \Throwable $e ) : string
512512
{
513513
if( $this->getCaptureOutput() )
514514
{

versionlog.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
## 0.8.7
2+
* Updated error handling.
23

34
## 0.8.6 2025-11-10
45

0 commit comments

Comments
 (0)