mirror of
https://github.com/eworm-de/routeros-scripts.git
synced 2025-06-20 17:15:48 +02:00
update-tunnelbroker: :do ... on-error=... -> :onerror ... do=...
This commit is contained in:
parent
10ac816348
commit
205bcce6f9
1 changed files with 3 additions and 3 deletions
|
@ -41,12 +41,12 @@
|
|||
|
||||
:for I from=2 to=0 do={
|
||||
:if ($Data = false) do={
|
||||
:do {
|
||||
:onerror Err {
|
||||
:set Data ([ /tool/fetch check-certificate=yes-without-crl \
|
||||
("https://ipv4.tunnelbroker.net/nic/update?hostname=" . $Comment->"id") \
|
||||
user=($Comment->"user") password=($Comment->"pass") output=user as-value ]->"data");
|
||||
} on-error={
|
||||
$LogPrint debug $ScriptName ("Failed downloading, " . $I . " retries pending.");
|
||||
} do={
|
||||
$LogPrint debug $ScriptName ("Failed downloading: " . $Err . " - " . $I . " retries pending.");
|
||||
:delay 2s;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue