Browse Source

Add a check for min php version

nsITobin 2 years ago
parent
commit
8a4aaa24ec
1 changed files with 10 additions and 0 deletions
  1. 10 0
      base/src/utils.php

+ 10 - 0
base/src/utils.php

@@ -10,6 +10,13 @@
 namespace {
 // == | Setup | =======================================================================================================
 
+// Check that we can run on this version of PHP
+if (PHP_MAJOR_VERSION . PHP_MINOR_VERSION < '81') {
+  die('BinOC Metropolis Utilities: PHP 8.1 or newer is required.');
+}
+
+// --------------------------------------------------------------------------------------------------------------------
+
 // Do not allow this to be included more than once...
 if (defined('BINOC_UTILS')) {
   die('BinOC Metropolis Utilities: You may not include this file more than once.');
@@ -821,6 +828,9 @@ class gRegistryUtils {
 // ====================================================================================================================
 
 // == | Static Error Class | ==========================================================================================
+
+
+
 // ====================================================================================================================
 
 // == | Static Output Class | =========================================================================================