From d7f068fdbf4883f62e829be80287e3e0992b5639 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mr=C2=B7x?= Date: Tue, 27 Jul 2021 18:26:55 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E5=90=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- function.php | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/function.php b/function.php index ca0cc702..d11166c6 100644 --- a/function.php +++ b/function.php @@ -4,7 +4,6 @@ defined('APP_PATH') or define('APP_PATH', realpath(__DIR__ . '/../../')); use Annotation\Annotation; -use HttpServer\Http\Context; use HttpServer\Http\HttpParams; use HttpServer\Http\Request; use HttpServer\Http\Response; @@ -488,11 +487,7 @@ if (!function_exists('request')) { */ function request(): Request { - $request = Context::getContext('request'); - if ($request === null) { - $request = make('request', Request::class); - } - return $request; + return di(Request::class); } }