From 5bc3f7c648e1c19c1a42684aea8172b7b14b9569 Mon Sep 17 00:00:00 2001 From: "as2252258@163.com" Date: Tue, 27 Jul 2021 00:41:00 +0800 Subject: [PATCH] modify --- HttpServer/Controller.php | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/HttpServer/Controller.php b/HttpServer/Controller.php index 8e1271bb..a2e57c46 100644 --- a/HttpServer/Controller.php +++ b/HttpServer/Controller.php @@ -19,7 +19,7 @@ use Snowflake\Snowflake; * Class WebController * @package Snowflake\Snowflake\Web * @property-read HttpParams $input - * @property-read HttpHeaders $headers + * @property-read HttpHeaders $header */ class Controller { @@ -36,6 +36,20 @@ class Controller protected Request $request; + /** + * @var \HttpServer\Http\HttpParams + */ + #[Inject(className: 'input', withContext: true)] + protected HttpParams $input; + + + /** + * @var \HttpServer\Http\HttpHeaders + */ + #[Inject(className: 'header', withContext: true)] + protected HttpHeaders $header; + + /** * inject response *