<?php
use App\Kernel;
use Symfony\Component\ErrorHandler\Debug;
use Symfony\Component\VarDumper\VarDumper;
require_once dirname(__DIR__).'/vendor/autoload_runtime.php';
return function (array $context) {
if($_SERVER['REMOTE_ADDR'] == '13.36.8.110' || $_SERVER['REMOTE_ADDR'] == '3.143.166.126'){
$context['APP_DEBUG'] = true;
$context['APP_ENV'] = 'dev';
}
if ($context['APP_DEBUG'] ) {
umask(0000);
Debug::enable();
}else {
VarDumper::setHandler(function($var) {});
}
return new Kernel($context['APP_ENV'], (bool) $context['APP_DEBUG']);
};