Skip to content

Commit

Permalink
update rspotify crate to v0.12.0 (aquelemiguel#249)
Browse files Browse the repository at this point in the history
* updated rpsotify v0.11.6 -> v0.11.7

* updated rpspotify to 0.12.0

* fix clippy lints

* fix cargo fmt check
  • Loading branch information
SimonStjernholm authored and blimp4242 committed May 25, 2024
1 parent 61efafd commit 8ed1377
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions src/commands/play.rs
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,9 @@ pub async fn play(
.ok_or(ParrotError::Other("failed to fetch playlist"))?;

for url in urls.iter() {
let Ok(queue) = enqueue_track(&call, &QueryType::VideoLink(url.to_string())).await else {
let Ok(queue) =
enqueue_track(&call, &QueryType::VideoLink(url.to_string())).await
else {
continue;
};
update_queue_messages(&ctx.http, &ctx.data, &queue, guild_id).await;
Expand All @@ -195,7 +197,8 @@ pub async fn play(
.ok_or(ParrotError::Other("failed to fetch playlist"))?;

for (idx, url) in urls.into_iter().enumerate() {
let Ok(queue) = insert_track(&call, &QueryType::VideoLink(url), idx + 1).await else {
let Ok(queue) = insert_track(&call, &QueryType::VideoLink(url), idx + 1).await
else {
continue;
};
update_queue_messages(&ctx.http, &ctx.data, &queue, guild_id).await;
Expand Down Expand Up @@ -228,7 +231,9 @@ pub async fn play(
let mut insert_idx = 1;

for (i, url) in urls.into_iter().enumerate() {
let Ok(mut queue) = insert_track(&call, &QueryType::VideoLink(url), insert_idx).await else {
let Ok(mut queue) =
insert_track(&call, &QueryType::VideoLink(url), insert_idx).await
else {
continue;
};

Expand Down

0 comments on commit 8ed1377

Please sign in to comment.