From 6932d222b3ba77a5a8806ba2d174ad0e4644e057 Mon Sep 17 00:00:00 2001 From: auooru Date: Fri, 10 Apr 2020 01:15:12 +0800 Subject: [PATCH] fix: filename --- composer.json | 2 +- config/{cros.php => cors.php} | 0 src/CorsMiddleware.php | 2 +- 3 files changed, 2 insertions(+), 2 deletions(-) rename config/{cros.php => cors.php} (100%) diff --git a/composer.json b/composer.json index efbf6d6..3c932fb 100644 --- a/composer.json +++ b/composer.json @@ -32,7 +32,7 @@ }, "autoload-dev": { "psr-4": { - "Test\\Think\\": "tests" + "Test\\Think\\Cors\\": "tests" } }, "extra": { diff --git a/config/cros.php b/config/cors.php similarity index 100% rename from config/cros.php rename to config/cors.php diff --git a/src/CorsMiddleware.php b/src/CorsMiddleware.php index 30d1f53..de587b0 100644 --- a/src/CorsMiddleware.php +++ b/src/CorsMiddleware.php @@ -17,7 +17,7 @@ class CorsMiddleware public function __construct(Config $config) { - $conf = $config->get('cros', []); + $conf = $config->get('cors', []); $this->cors = new CorsCore( $conf['allowed_origins'] ?? [],