From 4157e89ab724f64c6eec942c853f76493b38e398 Mon Sep 17 00:00:00 2001 From: shimon Date: Wed, 19 Feb 2025 22:33:13 +0200 Subject: [PATCH] debug --- app/controllers/general.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/app/controllers/general.php b/app/controllers/general.php index b7ca785baf..abf4898938 100644 --- a/app/controllers/general.php +++ b/app/controllers/general.php @@ -91,12 +91,12 @@ function router(App $utopia, Database $dbForPlatform, callable $getProjectDB, Sw var_dump([ 'before' => $host ]); - - if (System::getEnv('_APP_OPTIONS_ROUTER_PROTECTION', 'disabled') === 'enabled') { - if ($host !== 'localhost' && $host !== APP_HOSTNAME_INTERNAL && $host !== System::getEnv('_APP_CONSOLE_DOMAIN', '')) { - throw new AppwriteException(AppwriteException::GENERAL_ACCESS_FORBIDDEN, 'Router protection does not allow accessing Appwrite over this domain. Please add it as custom domain to your project or disable _APP_OPTIONS_ROUTER_PROTECTION environment variable.'); - } - } +// +// if (System::getEnv('_APP_OPTIONS_ROUTER_PROTECTION', 'disabled') === 'enabled') { +// if ($host !== 'localhost' && $host !== APP_HOSTNAME_INTERNAL && $host !== System::getEnv('_APP_CONSOLE_DOMAIN', '')) { +// throw new AppwriteException(AppwriteException::GENERAL_ACCESS_FORBIDDEN, 'Router protection does not allow accessing Appwrite over this domain. Please add it as custom domain to your project or disable _APP_OPTIONS_ROUTER_PROTECTION environment variable.'); +// } +// } var_dump([ 'after' => $host