aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Christian Hesse <mail@eworm.de>2024-04-19 11:34:35 +0200
committerGravatar Christian Hesse <mail@eworm.de>2024-04-19 11:46:17 +0200
commit0f2a4aedab31a7f697158d3d34ac6ce08756ebce (patch)
tree22efe61f8c6ec5dd9103e19ccc63461be7713e5e
parentb0cd53f813be602edf59db2ec18e085d84fbebeb (diff)
global-functions: $CertificateDownload: remove with find...routeros-7.15rc1-1
... to make sure this does not break when the file does no longer exist. Starting with RouterOS 7.15rc1 the file is automatically removed on import.
-rw-r--r--global-functions.rsc2
1 files changed, 1 insertions, 1 deletions
diff --git a/global-functions.rsc b/global-functions.rsc
index 3b9f27c..66765bf 100644
--- a/global-functions.rsc
+++ b/global-functions.rsc
@@ -151,7 +151,7 @@
$WaitForFile $FileName;
/certificate/import file-name=$FileName passphrase="" as-value;
:delay 1s;
- /file/remove $FileName;
+ /file/remove [ find where name=$FileName ];
:foreach Cert in=[ /certificate/find where name~("^" . $FileName . "_[0-9]+\$") ] do={
$CertificateNameByCN [ /certificate/get $Cert common-name ];