From 09a2833242b062de3fe18f127e5c1dcf15408c8e Mon Sep 17 00:00:00 2001 From: Daniil Gentili Date: Sat, 19 Nov 2022 17:36:28 +0100 Subject: [PATCH] Update phar.php --- phar.php | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/phar.php b/phar.php index fdcccae..a0d53d9 100644 --- a/phar.php +++ b/phar.php @@ -40,12 +40,9 @@ class Installer */ public function __construct() { - if ((PHP_MAJOR_VERSION === 7 && PHP_MINOR_VERSION < 1) || PHP_MAJOR_VERSION < 7) { + if (PHP_MAJOR_VERSION < 8 || PHP_MINOR_VERSION < 1) { throw new \Exception('MadelineProto requires at least PHP 8.1.'); } - if ((PHP_MAJOR_VERSION === 8 && PHP_MINOR_VERSION < 1) || PHP_MAJOR_VERSION === 7) { - trigger_error('MadelineProto requires at least PHP 8.1.'); - } if (PHP_INT_SIZE < 8) { throw new \Exception('A 64-bit build of PHP is required to run MadelineProto, PHP 8.1 is required.'); } @@ -174,9 +171,6 @@ class Installer private static function load($release) { if ($release === null) { - if ((PHP_MAJOR_VERSION === 8 && PHP_MINOR_VERSION < 1) || PHP_MAJOR_VERSION === 7) { - throw new \Exception('MadelineProto requires at least PHP 8.1.'); - } throw new \Exception('Could not download MadelineProto, please check your internet connection and PHP configuration!'); } $phar = "madeline-$release.phar";