refactor(v2): inline network check_network_path delegate

Inlines `check_network_path` from crate::network::commands into
commands_v2/legacy_compat.rs. The legacy command was a one-line wrapper
over crate::network::is_network_path; the inlined v2 form calls
is_network_path directly with no behavior change.

Deletes the legacy #[tauri::command] definition in network/mod.rs.
Other tauri commands inside crate::network::commands remain (they have
no v2 delegates and keep being exported as their own legacy commands;
they will be addressed in a separate cleanup step if needed).

No frontend invoke changes required.

Step 6 of the legacy cleanup plan, group G (network path).

cc
This commit is contained in:
vicrodh committed 2026-04-26 18:21:26 -06:00
1 parent 145b589c2a
commit 81461bec32
2 files changed
+1 -7

No files matched your search

+1 -1
View File
@@ -721,7 +721,7 @@ pub async fn v2_get_track_by_path(
pub fn v2_check_network_path(
path: String,
) -> Result<crate::network::NetworkPathInfo, RuntimeError> {
Ok(crate::network::commands::check_network_path(path))
Ok(crate::network::is_network_path(std::path::Path::new(&path)))
}
#[tauri::command]
-6
View File
@@ -374,12 +374,6 @@ pub fn get_all_mounts() -> Vec<MountInfo> {
pub mod commands {
use super::*;
/// Check if a path is on a network filesystem
#[tauri::command]
pub fn check_network_path(path: String) -> NetworkPathInfo {
is_network_path(Path::new(&path))
}
/// Get all network mounts currently visible
#[tauri::command]
pub fn get_network_mounts_cmd() -> Vec<MountInfo> {