diff options
| author | winter | 2024-12-06 20:43:26 +0000 |
|---|---|---|
| committer | winter | 2024-12-06 20:43:26 +0000 |
| commit | e1ad307b531c27ec6bfaf8b4d018991b0d4a78f3 (patch) | |
| tree | 4ef08af2b4051d433bb929d5162474ac6777cab1 /WpfTest/HttpReturnStatus/InternalServerError.php | |
initial commit
hardcoded functionality mostly!
Diffstat (limited to 'WpfTest/HttpReturnStatus/InternalServerError.php')
| -rw-r--r-- | WpfTest/HttpReturnStatus/InternalServerError.php | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/WpfTest/HttpReturnStatus/InternalServerError.php b/WpfTest/HttpReturnStatus/InternalServerError.php new file mode 100644 index 0000000..0141e26 --- /dev/null +++ b/WpfTest/HttpReturnStatus/InternalServerError.php @@ -0,0 +1,16 @@ +<?php +namespace WpfTest\HttpReturnStatus; + +use WpfTest\HttpReturnStatus; + +class InternalServerError extends \Exception implements HttpReturnStatus { + public function __construct(\Exception $reason) { + $this->message = $reason->getMessage(); + } + public function httpCode(): int { + return 500; + } + public function httpReason(): string { + return "Internal Server Error"; + } +}
\ No newline at end of file |
