diff --git a/docs/update2fa.md b/docs/update2fa.md index 7ea6a147..74ab17e4 100644 --- a/docs/update2fa.md +++ b/docs/update2fa.md @@ -20,7 +20,7 @@ The params array can contain password (current password), new_password, email (o ```php try { - $MadelineProto->update2fa(['password' => 'current password', 'new_password' => 'New password', 'email' => 'daniil@daniil.it', 'hint' => 'ponies']); + yield $MadelineProto->update2fa(['password' => 'current password', 'new_password' => 'New password', 'email' => 'daniil@daniil.it', 'hint' => 'ponies']); } catch (RPCErrorException $e) { if (strpos($e->rpc, 'EMAIL_UNCONFIRMED_') !== false) { $Bool = yield $MadelineProto->account->confirmPasswordEmail(['code' => yield $MadelineProto->readline('Enter your email code: ')]);