|
@@ -1,5 +1,5 @@
|
|
use crate::clash;
|
|
use crate::clash;
|
|
-use crate::profiles;
|
|
|
|
|
|
+use crate::import;
|
|
use tauri::api::process::kill_children;
|
|
use tauri::api::process::kill_children;
|
|
|
|
|
|
#[tauri::command]
|
|
#[tauri::command]
|
|
@@ -10,7 +10,7 @@ pub fn cmd_restart_sidebar() {
|
|
|
|
|
|
#[tauri::command]
|
|
#[tauri::command]
|
|
pub async fn cmd_import_profile(url: String) -> Result<String, String> {
|
|
pub async fn cmd_import_profile(url: String) -> Result<String, String> {
|
|
- match profiles::import_profile(&url).await {
|
|
|
|
|
|
+ match import::import_profile(&url).await {
|
|
Ok(_) => Ok(String::from("success")),
|
|
Ok(_) => Ok(String::from("success")),
|
|
Err(_) => Err(String::from("error")),
|
|
Err(_) => Err(String::from("error")),
|
|
}
|
|
}
|