fixed url gen on user-upped tracks
This commit is contained in:
parent
30153cfb8a
commit
ada8193533
3 changed files with 5 additions and 5 deletions
|
@ -39,14 +39,14 @@ impl Cipher {
|
|||
}
|
||||
|
||||
#[wasm_bindgen]
|
||||
pub fn stream_url(md5_origin: &str, format: &str, id: i32, media_version: u8) -> String {
|
||||
pub fn stream_url(md5_origin: &str, format: &str, id: &str, media_version: u8) -> String {
|
||||
// md5 origin + format num + id + media version
|
||||
let metadata = [
|
||||
md5_origin.as_bytes(),
|
||||
&[b'\xa4'],
|
||||
format.as_bytes(),
|
||||
&[b'\xa4'],
|
||||
id.to_string().as_bytes(),
|
||||
id.as_bytes(),
|
||||
&[b'\xa4'],
|
||||
media_version.to_string().as_bytes(),
|
||||
].concat();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue