public/index.php line 5

Open in your IDE?
  1. <?php
  2. use App\Kernel;
  3. require_once dirname(__DIR__).'/vendor/autoload_runtime.php';
  4. header('Access-Control-Allow-Origin: *');
  5. header("Access-Control-Allow-Headers: X-API-KEY, Origin, X-Requested-With, Content-Type, Accept, Access-Control-Request-Method");
  6. header("Access-Control-Allow-Methods: GET, POST, OPTIONS, PUT, DELETE");
  7. header("Allow: GET, POST, OPTIONS, PUT, DELETE");
  8. $method $_SERVER['REQUEST_METHOD'];
  9. if ($method == "OPTIONS") {
  10.     die();
  11. }
  12. return function (array $context) {
  13.     return new Kernel($context['APP_ENV'], (bool) $context['APP_DEBUG']);
  14. };