diff --git a/src-tauri/src/cmds.rs b/src-tauri/src/cmds.rs
index 226b5579edccce90041edf2b1f18d0e5477189d1..2b968a3076828a25fd139149e399c0f37543d110 100644
--- a/src-tauri/src/cmds.rs
+++ b/src-tauri/src/cmds.rs
@@ -59,19 +59,27 @@ pub async fn update_profile(
   clash_state: State<'_, ClashState>,
   profiles_state: State<'_, ProfilesState>,
 ) -> Result<(), String> {
-  let url = {
+  let (url, opt) = {
     // must release the lock here
     let profiles = profiles_state.0.lock().unwrap();
     let item = wrap_err!(profiles.get_item(&index))?;
 
+    // check the profile type
+    if let Some(typ) = item.itype.as_ref() {
+      if *typ != "remote" {
+        ret_err!(format!("could not update the `{typ}` profile"));
+      }
+    }
+
     if item.url.is_none() {
       ret_err!("failed to get the item url");
     }
 
-    item.url.clone().unwrap()
+    (item.url.clone().unwrap(), item.option.clone())
   };
 
-  let item = wrap_err!(PrfItem::from_url(&url, None, None, option).await)?;
+  let fetch_opt = PrfOption::merge(opt, option);
+  let item = wrap_err!(PrfItem::from_url(&url, None, None, fetch_opt).await)?;
 
   let mut profiles = profiles_state.0.lock().unwrap();
   wrap_err!(profiles.update_item(index.clone(), item))?;
diff --git a/src-tauri/src/core/profiles.rs b/src-tauri/src/core/profiles.rs
index 6b7bdd51da87046d3887eb531af57dc225b1e590..afc1bf56ef7fc86df76930c1c2ded07871bbdf86 100644
--- a/src-tauri/src/core/profiles.rs
+++ b/src-tauri/src/core/profiles.rs
@@ -73,6 +73,31 @@ pub struct PrfOption {
   pub with_proxy: Option<bool>,
 }
 
+impl PrfOption {
+  pub fn merge(one: Option<Self>, other: Option<Self>) -> Option<Self> {
+    if one.is_some() && other.is_some() {
+      let mut one = one.unwrap();
+      let other = other.unwrap();
+
+      if let Some(val) = other.user_agent {
+        one.user_agent = Some(val);
+      }
+
+      if let Some(val) = other.with_proxy {
+        one.with_proxy = Some(val);
+      }
+
+      return Some(one);
+    }
+
+    if one.is_none() {
+      return other;
+    }
+
+    return one;
+  }
+}
+
 impl Default for PrfItem {
   fn default() -> Self {
     PrfItem {
@@ -414,9 +439,7 @@ impl Profiles {
         patch!(each, item, selected);
         patch!(each, item, extra);
         patch!(each, item, updated);
-
-        // can be removed
-        each.option = item.option;
+        patch!(each, item, option);
 
         self.items = Some(items);
         return self.save_file();
diff --git a/src-tauri/src/utils/help.rs b/src-tauri/src/utils/help.rs
index 133b0a58bf7cd1ff02282f0cb012eebba4b1167e..0613407815a0665f21524db9fde08bdaa3c961d4 100644
--- a/src-tauri/src/utils/help.rs
+++ b/src-tauri/src/utils/help.rs
@@ -68,7 +68,7 @@ macro_rules! wrap_err {
 /// return the string literal error
 #[macro_export]
 macro_rules! ret_err {
-  ($str: literal) => {
+  ($str: expr) => {
     return Err($str.into())
   };
 }