From a8f56444cea8e7cbc537f60fc97f01bccfedc138 Mon Sep 17 00:00:00 2001 From: vicrodh <103399283+vicrodh@users.noreply.github.com> Date: Sat, 14 Feb 2026 19:48:12 -0600 Subject: [PATCH] feat(v2-commands): fix parameter names for frontend compatibility - Use camelCase parameter names (albumId, trackId, artistId) to match frontend expectations - Add #[allow(non_snake_case)] to suppress warnings V2 commands are ready for testing. Full frontend migration pending: - Search commands need searchType parameter - Need to add get_user_info, login with full flow, etc. --- src-tauri/src/commands_v2.rs | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/src-tauri/src/commands_v2.rs b/src-tauri/src/commands_v2.rs index 07bb71b73..fe795da98 100644 --- a/src-tauri/src/commands_v2.rs +++ b/src-tauri/src/commands_v2.rs @@ -123,30 +123,33 @@ pub async fn v2_search_artists( /// Get album by ID (V2 - uses QbzCore) #[tauri::command] +#[allow(non_snake_case)] pub async fn v2_get_album( - album_id: String, + albumId: String, bridge: State<'_, CoreBridgeState>, ) -> Result { let bridge = bridge.get().await; - bridge.get_album(&album_id).await + bridge.get_album(&albumId).await } /// Get track by ID (V2 - uses QbzCore) #[tauri::command] +#[allow(non_snake_case)] pub async fn v2_get_track( - track_id: u64, + trackId: u64, bridge: State<'_, CoreBridgeState>, ) -> Result { let bridge = bridge.get().await; - bridge.get_track(track_id).await + bridge.get_track(trackId).await } /// Get artist by ID (V2 - uses QbzCore) #[tauri::command] +#[allow(non_snake_case)] pub async fn v2_get_artist( - artist_id: u64, + artistId: u64, bridge: State<'_, CoreBridgeState>, ) -> Result { let bridge = bridge.get().await; - bridge.get_artist(artist_id).await + bridge.get_artist(artistId).await }