From 8827803bb3eba90f9bc39f274fe3dfaba8acae1a Mon Sep 17 00:00:00 2001 From: Skylar Ittner Date: Mon, 23 Apr 2018 20:25:24 -0600 Subject: [PATCH] Close #3 --- public/index.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/public/index.php b/public/index.php index 460a3cd..f9f92d0 100644 --- a/public/index.php +++ b/public/index.php @@ -16,6 +16,9 @@ if (isset($_GET['theme']) && file_exists(__DIR__ . "/themes/" . preg_replace("/[ $theme = preg_replace("/[^A-Za-z0-9]/", '', $_GET['theme']); } else { $theme = $database->get("sites", "theme", ["siteid" => getsiteid()]); + if (!file_exists(__DIR__ . "/themes/$theme/theme.json")) { + $theme = "bootstrap"; + } } define("SITE_THEME", $theme);