diff --git a/Cargo.toml b/Cargo.toml index d730417..1f42c2a 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -7,7 +7,7 @@ edition = "2021" [dependencies] tokio = { version = "1", features = ["full"] } -ricq = "0.1" +ricq = { version = "0.1", git = "https://github.com/lz1998/ricq" } futures = "0.3" async-trait = "0.1" bytes = "1.1.0" @@ -34,7 +34,7 @@ chrono = "0.4" xml-rs = "0.8" async-recursion = "1.0.0" md5 = "0.7" -ricq-core = "0.1" +ricq-core = { version = "0.1", git = "https://github.com/lz1998/ricq" } [build-dependencies] #lust-build = { version = "*", registry = "crates-byted" } diff --git a/rust-toolchain.toml b/rust-toolchain.toml new file mode 100644 index 0000000..271800c --- /dev/null +++ b/rust-toolchain.toml @@ -0,0 +1,2 @@ +[toolchain] +channel = "nightly" \ No newline at end of file diff --git a/src/api_handler.rs b/src/api_handler.rs index d7119bf..780471c 100644 --- a/src/api_handler.rs +++ b/src/api_handler.rs @@ -2,7 +2,7 @@ use std::sync::Arc; use std::time::Duration; use ricq::structs::GroupMemberPermission; -use ricq_core::command::oidb_svc::music::{MusicShare, MusicType}; +use ricq_core::structs::{MusicShare, MusicVersion}; use crate::bot::Bot; use crate::error::{RCError, RCResult}; @@ -495,9 +495,12 @@ pub async fn handle_send_music(bot: &Arc, req: SendMusicReq) -> RCResult MusicType::QQ, - "cloud" => MusicType::Cloud, - _ => MusicType::QQ, + "qq" => MusicVersion::QQ, + "cloud" => MusicVersion::NETEASE, + "migu" => MusicVersion::MIGU, + "kugou" => MusicVersion::KUGOU, + "kuwo" => MusicVersion::KUWO, + _ => MusicVersion::QQ, }; if req.group_id != 0 { bot.client