mirror of
https://github.com/LHY0125/PathEditor.git
synced 2026-06-29 09:55:56 +08:00
fix: backup_registry 改为内部读取注册表当前值,不再依赖前端传入数据
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -259,8 +259,8 @@ export const useAppStore = create<AppState>((set, get) => ({
|
||||
if (!window.confirm('PATH 长度超过建议值,是否继续保存?')) { set({ isSaving: false }); return; }
|
||||
}
|
||||
|
||||
// 备份(失败时通知用户)
|
||||
invoke('backup_registry', { customDir: null, sysPaths, userPaths })
|
||||
// 备份当前注册表(保存前备份旧值,失败仅警告不中断)
|
||||
invoke('backup_registry', { customDir: null })
|
||||
.catch(() => set({ statusMessage: i18n.t('status.warning_backup') }));
|
||||
|
||||
const [sysResult, userResult] = await Promise.allSettled([
|
||||
|
||||
Reference in New Issue
Block a user