mirror of
https://github.com/CharaChorder/DeviceManager.git
synced 2026-01-21 17:32:41 +00:00
fix: zero/engine backups should be x backups
This commit is contained in:
@@ -97,9 +97,13 @@ export function restoreFromFile(
|
||||
let backupDevice = recent[1].device;
|
||||
if (backupDevice === "TWO" || backupDevice === "M4G")
|
||||
backupDevice = "ONE";
|
||||
else if (backupDevice === "ZERO" || backupDevice === "ENGINE")
|
||||
backupDevice = "X";
|
||||
let currentDevice = get(serialPort)?.device;
|
||||
if (currentDevice === "TWO" || currentDevice === "M4G")
|
||||
currentDevice = "ONE";
|
||||
else if (currentDevice === "ZERO" || currentDevice === "ENGINE")
|
||||
currentDevice = "X";
|
||||
|
||||
if (backupDevice !== currentDevice) {
|
||||
alert("Backup is incompatible with this device");
|
||||
|
||||
Reference in New Issue
Block a user