From c6a402927dde12009a2e324b7db18c1a2fbe18f6 Mon Sep 17 00:00:00 2001 From: recanman <29310982+recanman@users.noreply.github.com> Date: Sat, 5 Oct 2024 00:00:17 -0700 Subject: [PATCH] refactor: replace require with require_once, remove unneeded semicolon --- index.php | 4 ++-- templates/index.php | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/index.php b/index.php index 27dc946..7ba03be 100644 --- a/index.php +++ b/index.php @@ -20,7 +20,7 @@ $api_cg = json_decode(file_get_contents('coingecko.json'), true); // Configuration file $config = []; if (file_exists('config.php')) { - $config = require 'config.php'; + $config = require_once 'config.php'; } $display_servers_guru = isset($config['servers_guru']) && $config['servers_guru'] === true; @@ -106,5 +106,5 @@ foreach (array_reverse($preferred_currencies) as $currency) { } // Output the HTML -require 'templates/index.php'; +require_once 'templates/index.php'; ?> diff --git a/templates/index.php b/templates/index.php index c7c8575..1e4cd0b 100644 --- a/templates/index.php +++ b/templates/index.php @@ -121,7 +121,7 @@