diff --git a/src/EventObservers/EventHandler.php b/src/EventObservers/EventHandler.php index 6c6e2bf..7272684 100644 --- a/src/EventObservers/EventHandler.php +++ b/src/EventObservers/EventHandler.php @@ -41,7 +41,7 @@ class EventHandler extends \danog\MadelineProto\EventHandler public function onAny($update): void { - $session = Client::getSessionName($this->API->wrapper->session); + $session = Client::getSessionName($this->API->wrapper->session ?? null); Logger::getInstance()->info("Received update from session: {$session}"); foreach (static::$eventListeners as $clientId => $callback) {