First commit !

This commit is contained in:
mcndave committed 2019-07-03 13:28:35 +00:00
commit 755961039c
8 files changed
+140

No files matched your search

+26
View File
@@ -0,0 +1,26 @@
<?php
namespace TheBugs\Exception;
class JavascriptException extends \Exception {
protected $url;
protected $stacktrace;
public function __construct(string $message, int $code, Exception $previous = null, string $file, int $line, string $url, array $trace)
{
$this->message = $message;
$this->code = $code;
$this->previous = $previous;
$this->file = $file;
$this->line = $line;
$this->url = $url;
$this->stacktrace = $trace;
}
public function __toString() {
return __CLASS__ . ": [{$this->url}:{$this->code}]: {$this->message}\n" . json_encode($this->stacktrace);
}
}