diff --git a/README.md b/README.md index f8be0fa13..d45307e11 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ Created by Daniil Gen `#StandWithUkraine πŸ‡ΊπŸ‡¦` -[![status-badge](https://ci.daniil.it/api/badges/danog/MadelineProto/status.svg?branch=stable)](https://ci.daniil.it/danog/MadelineProto/branches/stable) +[![status-badge](https://ci.daniil.it/api/badges/danog/MadelineProto/status.svg?branch=v8)](https://ci.daniil.it/danog/MadelineProto/branches/v8) Do join the official channel, [@MadelineProto](https://t.me/MadelineProto) and the [support groups](https://t.me/pwrtelegramgroup)! diff --git a/src/MTProtoTools/PeerHandler.php b/src/MTProtoTools/PeerHandler.php index f91cb7ecd..2105bdd21 100644 --- a/src/MTProtoTools/PeerHandler.php +++ b/src/MTProtoTools/PeerHandler.php @@ -874,7 +874,7 @@ trait PeerHandler */ public function getFullInfo(mixed $id): array { - $partial = ($this->getInfo($id)); + $partial = $this->getInfo($id); if (\time() - ($this->fullChatLastUpdated($partial['bot_api_id'])) < $this->getSettings()->getPeer()->getFullInfoCacheTime()) { return \array_merge($partial, $this->full_chats[$partial['bot_api_id']]); } diff --git a/src/MTProtoTools/ReferenceDatabase.php b/src/MTProtoTools/ReferenceDatabase.php index 560d000ae..f1c017d74 100644 --- a/src/MTProtoTools/ReferenceDatabase.php +++ b/src/MTProtoTools/ReferenceDatabase.php @@ -437,7 +437,7 @@ final class ReferenceDatabase implements TLCallback \ksort($locationValue['origins']); $this->db[$location] = $locationValue; $count = 0; - foreach (($this->db[$location])['origins'] as $originType => &$origin) { + foreach ($this->db[$location]['origins'] as $originType => $origin) { $count++; $this->API->logger->logger("Try {$count} refreshing file reference with origin type {$originType}", Logger::VERBOSE); switch ($originType) { diff --git a/src/Magic.php b/src/Magic.php index 0b843ae72..e69563fb9 100644 --- a/src/Magic.php +++ b/src/Magic.php @@ -282,9 +282,9 @@ final class Magic self::$zerowebhost = isset($_SERVER['SERVER_ADMIN']) && \strpos($_SERVER['SERVER_ADMIN'], '000webhost.io'); self::$can_getmypid = !self::$altervista && !self::$zerowebhost; self::$version = null; - if (\file_exists(__DIR__.'/../.git/refs/heads/stable')) { + if (\file_exists(__DIR__.'/../.git/refs/heads/v8')) { try { - self::$version = \trim(@\file_get_contents(__DIR__.'/../.git/refs/heads/stable')); + self::$version = \trim(@\file_get_contents(__DIR__.'/../.git/refs/heads/v8')); } catch (Throwable $e) { } } diff --git a/ton/README.md b/ton/README.md index 0fda1cb6e..a2a72c27b 100644 --- a/ton/README.md +++ b/ton/README.md @@ -30,8 +30,8 @@ $API = new API( $API->async(true); $API->loop( function () use ($API) { - yield $API->connect(__DIR__.'/ton-lite-client-test1.config.json'); - var_dump(yield $API->liteServer->getTime()); + $API->connect(__DIR__.'/ton-lite-client-test1.config.json'); + var_dump($API->liteServer->getTime()); } ); ``` diff --git a/tools/makephar.php b/tools/makephar.php index 1aaa4951a..211cbf894 100755 --- a/tools/makephar.php +++ b/tools/makephar.php @@ -20,8 +20,8 @@ if (!isset($argv[3])) { $p = new Phar(__DIR__.'/../'.$argv[2], 0, $argv[2]); $p->buildFromDirectory(realpath($argv[1]), '/^((?!tests).)*(\.php|\.py|\.exe|\.tl|\.json|\.dat|\.h)$/i'); -$p->addFromString('vendor/danog/madelineproto/.git/refs/heads/stable', $argv[3]); -$p->addFromString('.git/refs/heads/stable', $argv[3]); +$p->addFromString('vendor/danog/madelineproto/.git/refs/heads/v8', $argv[3]); +$p->addFromString('.git/refs/heads/v8', $argv[3]); $p->setStub('