Files
dewemoji-api/app/bootstrap.php
2025-08-30 14:27:01 +07:00

13 lines
353 B
PHP

<?php
// app/bootstrap.php — env + errors
$cfg = require __DIR__.'/../config/env.php';
date_default_timezone_set('UTC');
error_reporting(E_ALL);
ini_set('display_errors', $cfg['debug'] ? '1' : '0');
function cfg(string $key, $default=null) {
static $cfg;
if (!$cfg) $cfg = require __DIR__.'/../config/env.php';
return $cfg[$key] ?? $default;
}