aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Christian Hesse <mail@eworm.de>2024-07-05 15:32:49 +0200
committerGravatar Christian Hesse <mail@eworm.de>2024-07-08 10:05:11 +0200
commit25135b64e549e129914b9b5dfb74ca2011ee3d5d (patch)
tree059b10171a04131e348fe2c2b12956677b6da98e
parent235737c2327cf377a1208dc96af53d9c8642b305 (diff)
backup-partition: check that target is inactive
-rw-r--r--backup-partition.rsc4
1 files changed, 2 insertions, 2 deletions
diff --git a/backup-partition.rsc b/backup-partition.rsc
index 211db0f..34cdc8f 100644
--- a/backup-partition.rsc
+++ b/backup-partition.rsc
@@ -60,10 +60,10 @@
}
:local FallbackToName [ /partitions/get $ActiveRunning fallback-to ];
- :local FallbackTo [ /partition/find where name=$FallbackToName ];
+ :local FallbackTo [ /partition/find where name=$FallbackToName !active ];
:if ([ :len $FallbackTo ] < 1) do={
- $LogPrint error $ScriptName ("There is no partition with name '" . $FallbackToName . "'.");
+ $LogPrint error $ScriptName ("There is no inactive partition named '" . $FallbackToName . "'.");
:set PackagesUpdateBackupFailure true;
:error false;
}