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();
|
||||
}
|
||||
|
||||
|
||||
@@ -216,7 +216,7 @@ final class Search
|
||||
}));
|
||||
}
|
||||
}
|
||||
if (defined('APP_ENV') && APP_ENV === 'staging') {
|
||||
if (defined('APP_SEARCH_DEBUG') && APP_SEARCH_DEBUG) {
|
||||
$logOk = [
|
||||
'status' => 'ok',
|
||||
'sql' => $sql,
|
||||
|
||||
Reference in New Issue
Block a user