Skip to content

Commit 891e400

Browse files
authored
Fix clippy warnings (#3358)
1 parent 685b77a commit 891e400

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

command_attr/src/util.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ impl LitExt for Lit {
3030
if let Lit::Bool(b) = self {
3131
b.value
3232
} else {
33-
self.to_str().parse().unwrap_or_else(|_| panic!("expected bool from {:?}", self))
33+
self.to_str().parse().unwrap_or_else(|_| panic!("expected bool from {self:?}"))
3434
}
3535
}
3636

examples/testing/src/main.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -219,7 +219,7 @@ async fn message(ctx: &Context, msg: Message) -> Result<(), serenity::Error> {
219219
} else if let Some(forum_post_url) = msg.content.strip_prefix("deleteforumpost ") {
220220
let (_guild_id, channel_id, _message_id) =
221221
serenity::utils::parse_message_url(forum_post_url).unwrap();
222-
msg.channel_id.say(ctx, format!("Deleting <#{}> in 10 seconds...", channel_id)).await?;
222+
msg.channel_id.say(ctx, format!("Deleting <#{channel_id}> in 10 seconds...")).await?;
223223
tokio::time::sleep(std::time::Duration::from_secs(10)).await;
224224
channel_id.delete(ctx).await?;
225225
} else {

0 commit comments

Comments
 (0)