mirror of
https://github.com/Corfirean/coa-server-manager.git
synced 2026-11-19 19:25:56 +00:00
fix(client): preserve originals and verify race patch lifecycle
This commit is contained in:
1 parent
d86a1676fe
commit
7d7bc530ec
6 files changed
+445
-130
No files matched your search
@@ -699,6 +699,13 @@ async fn custom_races_install(app: AppHandle, state: State<'_, AppState>, id: St
|
||||
result
|
||||
}
|
||||
|
||||
#[tauri::command]
|
||||
async fn custom_races_uninstall(state: State<'_, AppState>, id: String) -> std::result::Result<(), UiError> {
|
||||
let ctx = client_context(&state, &id)?;
|
||||
let _guard = BusyGuard::acquire(&state, &id)?;
|
||||
blocking(move || coa_core::custom_races::uninstall_client_patches(&ctx.require()?)).await
|
||||
}
|
||||
|
||||
#[tauri::command]
|
||||
async fn custom_races_toggle_client(state: State<'_, AppState>, id: String, enabled: bool) -> std::result::Result<(), UiError> {
|
||||
let root = path_of(&state, &id)?;
|
||||
@@ -1764,6 +1771,7 @@ pub fn run() {
|
||||
console_command,
|
||||
custom_races_status,
|
||||
custom_races_install,
|
||||
custom_races_uninstall,
|
||||
custom_races_toggle_client
|
||||
])
|
||||
.run(tauri::generate_context!())
|
||||
|
||||
Reference in new issue
Block a user