private function bootstrapApplicationEnvironment($appBootstrap, $appenv, $debug)
    {
        $appBootstrap = $this->normalizeBootstrapClass($appBootstrap);

        $this->middleware = new $appBootstrap;
        if ($this->middleware instanceof ApplicationEnvironmentAwareInterface) {
            $this->middleware->initialize($appenv, $debug);
        }
    }