Skip to content

Commit 291568c

Browse files
committed
cargo update
1 parent f6b9c5a commit 291568c

File tree

3 files changed

+11
-6
lines changed

3 files changed

+11
-6
lines changed

Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ edition = "2021"
77

88
[dependencies]
99
tokio = { version = "1", features = ["full"] }
10-
ricq = "0.1"
10+
ricq = { version = "0.1", git = "https://github.com/lz1998/ricq" }
1111
futures = "0.3"
1212
async-trait = "0.1"
1313
bytes = "1.1.0"
@@ -34,7 +34,7 @@ chrono = "0.4"
3434
xml-rs = "0.8"
3535
async-recursion = "1.0.0"
3636
md5 = "0.7"
37-
ricq-core = "0.1"
37+
ricq-core = { version = "0.1", git = "https://github.com/lz1998/ricq" }
3838

3939
[build-dependencies]
4040
#lust-build = { version = "*", registry = "crates-byted" }

rust-toolchain.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
[toolchain]
2+
channel = "nightly"

src/api_handler.rs

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ use std::sync::Arc;
22
use std::time::Duration;
33

44
use ricq::structs::GroupMemberPermission;
5-
use ricq_core::command::oidb_svc::music::{MusicShare, MusicType};
5+
use ricq_core::structs::{MusicShare, MusicVersion};
66

77
use crate::bot::Bot;
88
use crate::error::{RCError, RCResult};
@@ -495,9 +495,12 @@ pub async fn handle_send_music(bot: &Arc<Bot>, req: SendMusicReq) -> RCResult<Se
495495
music_url: req.music_url,
496496
};
497497
let music_type = match req.r#type.as_str() {
498-
"qq" => MusicType::QQ,
499-
"cloud" => MusicType::Cloud,
500-
_ => MusicType::QQ,
498+
"qq" => MusicVersion::QQ,
499+
"cloud" => MusicVersion::NETEASE,
500+
"migu" => MusicVersion::MIGU,
501+
"kugou" => MusicVersion::KUGOU,
502+
"kuwo" => MusicVersion::KUWO,
503+
_ => MusicVersion::QQ,
501504
};
502505
if req.group_id != 0 {
503506
bot.client

0 commit comments

Comments
 (0)