From e9861d0c478f47734a611b219b7f228a69066898 Mon Sep 17 00:00:00 2001 From: morgan Date: Fri, 17 Jan 2025 17:20:45 +0100 Subject: [PATCH] Update admin controller --- classes/Workspace.php | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/classes/Workspace.php b/classes/Workspace.php index f86cf261d..958232f87 100644 --- a/classes/Workspace.php +++ b/classes/Workspace.php @@ -88,12 +88,11 @@ public function createHtAccess(string $modulePath): void RewriteEngine On - # Si on accède au dossier "log", on autorise l'accès - RewriteCond %{REQUEST_URI} ^/log/ [NC] - RewriteRule ^ - [L] - - # Sinon, on interdit l'accès + RewriteCond %{REQUEST_URI} ^.*/autoupgrade/logs/ [NC] + RewriteCond %{REQUEST_URI} !\.txt$ [NC] RewriteRule ^ - [F] + + RewriteRule ^ - [L] HTACCESS; if (!file_exists($filePath)) { @@ -106,7 +105,7 @@ public function createHtAccess(string $modulePath): void /** * @throws IOException */ - public function init($modulePath): void + public function init(string $modulePath): void { $this->createFolders(); $this->createHtAccess($modulePath);