mirror of
https://github.com/filp/whoops.git
synced 2026-09-04 22:48:11 +00:00
Modify example to include namespace in exception name
This commit is contained in:
+7
-2
@@ -12,17 +12,22 @@
|
||||
*
|
||||
* Or just run it through apache/nginx/what-have-yous as usual.
|
||||
*/
|
||||
require __DIR__ . '/vendor/autoload.php';
|
||||
|
||||
namespace Damnit\Example;
|
||||
use Damnit\Run;
|
||||
use Damnit\Handler\PrettyPage;
|
||||
use Exception as BaseException;
|
||||
|
||||
require __DIR__ . '/vendor/autoload.php';
|
||||
|
||||
class Exception extends BaseException {}
|
||||
|
||||
$run = new Run;
|
||||
$run->pushHandler(new PrettyPage);
|
||||
$run->register();
|
||||
|
||||
function fooBar() {
|
||||
throw new RuntimeException("hello, world!");
|
||||
throw new Exception("Something broke!");
|
||||
}
|
||||
|
||||
function bar()
|
||||
|
||||
Reference in New Issue
Block a user