commit changes
This commit is contained in:
@@ -24,11 +24,10 @@ final class Database
|
||||
} catch (\PDOException $e) {
|
||||
http_response_code(500);
|
||||
|
||||
$env = defined('APP_ENV') ? APP_ENV : 'prod';
|
||||
$dbDebug = defined('APP_DB_DEBUG') && APP_DB_DEBUG;
|
||||
$details = 'Database connection error.';
|
||||
|
||||
if ($env !== 'prod' || $dbDebug) {
|
||||
if ($dbDebug) {
|
||||
$details .= ' ' . $e->getMessage();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user