Updated grammers.

Signed-off-by: Pavel Kirilin <win10@list.ru>
This commit is contained in:
2024-07-26 17:56:22 +02:00
parent 0b943c56c4
commit 8cad92b7e3
3 changed files with 699 additions and 731 deletions

1419
Cargo.lock generated

File diff suppressed because it is too large Load Diff

View File

@ -18,9 +18,9 @@ dotenvy = "^0.15.6"
dyn-clone = "1.0.10"
fern = { version = "0.6.1", features = ["chrono", "colored"] }
futures = "0.3.26"
grammers-client = { version = "0.4.0", features = ["markdown", "html"] }
grammers-tl-types = { version = "0.4.0" }
grammers-session = "0.4.0"
grammers-client = { version = "~0.6", features = ["markdown", "html"] }
grammers-tl-types = { version = "~0.6" }
grammers-session = "~0.5.0"
lazy_static = "1.4.0"
log = "0.4.17"
rand = "0.8.5"

View File

@ -47,9 +47,8 @@ async fn authorize(
web_code: Arc<RwLock<Option<String>>>,
) -> anyhow::Result<()> {
log::info!("Requesting login code.");
let token = client
.request_login_code(&args.phone, args.app_id, &args.api_hash)
.await?;
let token = client.request_login_code(&args.phone).await?;
// args.app_id, &args.api_hash
let mut code = None;
// Check for code to becom available every second.