From 9f2bae5017b18f7fc08665e98403faf7a8d6bc0c Mon Sep 17 00:00:00 2001 From: qkqpttgf <45693631+qkqpttgf@users.noreply.github.com> Date: Fri, 31 Jan 2020 12:33:48 +0800 Subject: [PATCH] admin can manage the dir contain index.html --- theme/classic.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/theme/classic.php b/theme/classic.php index 3ad8f8a..b822682 100644 --- a/theme/classic.php +++ b/theme/classic.php @@ -216,7 +216,7 @@ if (isset($file['file'])) { if ($_SERVER['admin'] or (substr($file['name'],0,1) !== '.' and $file['name'] !== getConfig('passfile') ) ) { if (strtolower($file['name']) === 'readme.md') $readme = $file; - if (strtolower($file['name']) === 'index.html') { + if (strtolower($file['name']) === 'index.html' && !$_SERVER['admin']) { $html = curl_request(fetch_files(spurlencode(path_format($path . '/' .$file['name']),'/'))['@microsoft.graph.downloadUrl'])['body']; return output($html,200); }