Code refactoring
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
pub mod api;
|
||||
pub mod config;
|
||||
pub mod responses;
|
||||
pub mod the_rest;
|
||||
pub mod util;
|
||||
|
||||
@@ -218,11 +217,11 @@ async fn cleanup(
|
||||
|
||||
async fn is_queue_empty(
|
||||
app: &config::App,
|
||||
) -> Result<(bool, responses::fetch_next_queue_item::SongQueueItem), reqwest::Error> {
|
||||
match api::fetch_next_queue_item(app).await {
|
||||
) -> Result<(bool, api::fetch_next_queue_item::response::SongQueueItem), reqwest::Error> {
|
||||
match api::fetch_next_queue_item::fetch_next_queue_item(app).await {
|
||||
Ok(response) => {
|
||||
match response
|
||||
.json::<responses::fetch_next_queue_item::SongQueueItem>()
|
||||
.json::<api::fetch_next_queue_item::response::SongQueueItem>()
|
||||
.await
|
||||
{
|
||||
Ok(response) => {
|
||||
|
Reference in New Issue
Block a user