mirror of
https://github.com/TheFunny/TelegramTwitterMediaBot.git
synced 2026-09-23 23:32:05 +00:00
fix(lint): resolve clippy warnings from rust 1.98
- photo.rs: chunks_exact(4)/(2) -> as_chunks::<N>().0 (chunks_exact_to_as_chunks, the new lint prefers the compile-time-checked slice split) - send.rs: box the Task inside SendError so the error fits the result_large_err limit (Task is ~400 bytes; the error now moves through Result as a pointer); unbox with *task at the two enqueue_retry call sites (handlers/urls.rs, handlers/callback.rs) cargo clippy --workspace --all-targets is now warning-free; the remaining proc-macro-error2 future-incompat note is upstream (teloxide -> aquamarine) and unfixable locally. Full test suite passes.
This commit is contained in:
@@ -211,7 +211,7 @@ async fn dispatch_send(
|
||||
"send for [key={}] failed, queued for retry in {delay_seconds:.1}s",
|
||||
log_key(url)
|
||||
);
|
||||
enqueue_retry(ctx.task_queue, task, delay_seconds).await;
|
||||
enqueue_retry(ctx.task_queue, *task, delay_seconds).await;
|
||||
let _ = reply(
|
||||
ctx.sender,
|
||||
chat_id,
|
||||
|
||||
Reference in New Issue
Block a user