diff --git a/src/danog/MadelineProto/ApiWrappers/Start.php b/src/danog/MadelineProto/ApiWrappers/Start.php index 9b4209a1..0cecec04 100644 --- a/src/danog/MadelineProto/ApiWrappers/Start.php +++ b/src/danog/MadelineProto/ApiWrappers/Start.php @@ -117,7 +117,7 @@ trait Start $this->gettingApiId = false; return $app; } - yield from $this->webAPIEcho(Lang::$current_lang['apiParamsError']); + yield $this->webAPIEcho(Lang::$current_lang['apiParamsError']); } return null; } @@ -128,7 +128,7 @@ trait Start yield from $this->myTelegramOrgWrapper->login($_POST['phone_number']); yield $this->webAPIEcho(); } catch (\Throwable $e) { - yield from $this->webAPIEcho(\sprintf(Lang::$current_lang['apiError'], $e->getMessage())); + yield $this->webAPIEcho(\sprintf(Lang::$current_lang['apiError'], $e->getMessage())); } } private function webAPICompleteLogin(): \Generator @@ -136,9 +136,9 @@ trait Start try { yield from $this->myTelegramOrgWrapper->completeLogin($_POST['code']); } catch (\danog\MadelineProto\RPCErrorException $e) { - yield from $this->webAPIEcho(\sprintf(Lang::$current_lang['apiError'], $e->getMessage())); + yield $this->webAPIEcho(\sprintf(Lang::$current_lang['apiError'], $e->getMessage())); } catch (\danog\MadelineProto\Exception $e) { - yield from $this->webAPIEcho(\sprintf(Lang::$current_lang['apiError'], $e->getMessage())); + yield $this->webAPIEcho(\sprintf(Lang::$current_lang['apiError'], $e->getMessage())); } } private function webAPICreateApp(): \Generator @@ -149,9 +149,9 @@ trait Start $app = (yield from $this->myTelegramOrgWrapper->createApp($params)); return $app; } catch (\danog\MadelineProto\RPCErrorException $e) { - yield from $this->webAPIEcho(\sprintf(Lang::$current_lang['apiError'], $e->getMessage())); + yield $this->webAPIEcho(\sprintf(Lang::$current_lang['apiError'], $e->getMessage())); } catch (\danog\MadelineProto\Exception $e) { - yield from $this->webAPIEcho(\sprintf(Lang::$current_lang['apiError'], $e->getMessage())); + yield $this->webAPIEcho(\sprintf(Lang::$current_lang['apiError'], $e->getMessage())); } } }