From 07c599506515e68db13b73ddd71a8dd2899fa9b0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=B2=81=E6=A0=91=E4=BA=BA?= Date: Fri, 20 Sep 2024 23:42:19 +0100 Subject: [PATCH] [wasm/kuwo] feat: expose resource id metadata --- um_wasm/src/exports/kuwo.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/um_wasm/src/exports/kuwo.rs b/um_wasm/src/exports/kuwo.rs index e037a61..50df94b 100644 --- a/um_wasm/src/exports/kuwo.rs +++ b/um_wasm/src/exports/kuwo.rs @@ -23,6 +23,12 @@ impl JsKuwoHeader { pub fn quality_id(&self) -> u32 { self.0.get_quality_id() } + + /// Get resource id + #[wasm_bindgen(getter, js_name=resourceId)] + pub fn resource_id(&self) -> u32 { + self.0.resource_id + } } /// Create a decipher instance for "BoDian Music".