mirror of
https://github.com/Supernova3339/anonupload.git
synced 2026-02-28 01:00:44 +01:00
Apply fixes from StyleCI
This commit is contained in:
12
error.php
12
error.php
@@ -1,14 +1,14 @@
|
||||
<?php
|
||||
|
||||
$code = $_SERVER['REDIRECT_STATUS'];
|
||||
$codes = array(
|
||||
$codes = [
|
||||
403 => 'Forbidden',
|
||||
404 => '404 Not Found',
|
||||
500 => 'Internal Server Error'
|
||||
);
|
||||
500 => 'Internal Server Error',
|
||||
];
|
||||
$source_url = 'http'.((!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] != 'off') ? 's' : '').'://'.$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI'];
|
||||
if (array_key_exists($code, $codes) && is_numeric($code)) {
|
||||
die("Error $code: {$codes[$code]}");
|
||||
exit("Error $code: {$codes[$code]}");
|
||||
} else {
|
||||
die('Unknown error');
|
||||
exit('Unknown error');
|
||||
}
|
||||
?>
|
||||
Reference in New Issue
Block a user