[ERROR] You are not logged in
"; exit(); } elseif ($_SESSION['id'] != 1) { echo "[ERRO] You cannot use Autofix as an Admin currently.
"; exit(); } define('ROOT', true); // Only run scripts from this file echo "==== Databases ====
"; require_once "fix/_database.php"; echo "==== Folders ====
"; require_once "fix/_folders.php"; $timer_end = microtime(true); $timer_diff = ($timer_end - $timer_start); $timer_diff = round($timer_diff, 6) * 1000; echo "[INFO] Autofix complete in $timer_diff ms
"; } elseif (isset($_POST['check'])) { if (empty($_SESSION['id'])) { echo "[ERROR] You are not logged in
"; exit(); } elseif ($_SESSION['id'] != 1) { echo "[ERRO] You cannot use Autofix as an Admin currently.
"; exit(); } $timer_start = microtime(true); $autofix_enable = false; $results = array(); // Array to store results define('ROOT', true); // Only run scripts from this file include_once "check/_dir.php"; include_once "check/_json.php"; include_once "check/_perms.php"; include_once "check/_versions.php"; include_once "check/_database.php"; if (empty($results)) { echo "No errors! Lookin' good :3
"; } else { foreach ($results as $result) { if ($result['type'] == 'critical') { echo "Critical "; } elseif ($result['type'] == 'warning') { echo "
Warning "; } elseif ($result['type'] == 'success') { echo "
Success "; } if ($result['fix'] == 'auto') { echo "Auto fix available "; $autofix_enable = true; } elseif ($result['fix'] == 'manual') { echo "Manual fix required "; } if (isset($result['link'])) { echo "Recources "; } echo $result['message']."
"; } } $timer_end = microtime(true); $timer_diff = ($timer_end - $timer_start); $timer_diff = round($timer_diff, 6) * 1000; echo "Scan complete in $timer_diff ms
"; if ($autofix_enable) { echo ""; } } else { echo "Warning Bruh, what do you want?
"; }