From ce4cb8b06bad9a45daaca9426995454da2f037c1 Mon Sep 17 00:00:00 2001 From: Jackhr <63526062+Jackhr-arch@users.noreply.github.com> Date: Sat, 29 Jun 2024 17:42:48 +0000 Subject: [PATCH] fix an import issue --- clashtui/backend/src/backend/impl_profile.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/clashtui/backend/src/backend/impl_profile.rs b/clashtui/backend/src/backend/impl_profile.rs index 3389846..8144213 100644 --- a/clashtui/backend/src/backend/impl_profile.rs +++ b/clashtui/backend/src/backend/impl_profile.rs @@ -1,5 +1,5 @@ use super::ClashBackend; -use crate::utils::{extract_domain, get_file_names, ipc, is_yaml, parse_yaml}; +use crate::{consts::TMP_PATH, utils::{extract_domain, get_file_names, ipc, is_yaml, parse_yaml}}; use std::{ fs::{create_dir_all, File}, io::Error, @@ -547,7 +547,7 @@ fn try_create_file>(path: P) -> Result { Err(e) => { if e.kind() == std::io::ErrorKind::PermissionDenied { Ok(CrtFile::Tmp( - File::create(crate::consts::TMP_PATH).map_err(|e| e.to_string())?, + File::create(TMP_PATH).map_err(|e| e.to_string())?, )) } else { Err(format!("Unexpected Error: {e}"))