Skip to main content

duplicate_profile

Function duplicate_profile 

Source
pub async fn duplicate_profile(
    app: AppHandle,
    scheduler: State<'_, Scheduler>,
    source: String,
    name: String,
) -> Result<(), String>
Expand description

Copy source’s settings into a brand-new profile named name without flipping the active profile. Avoids the switch-then-create dance that used to fire profile:changed mid-duplication and clobber unsaved hook drafts.