:global GlobalFuncReady false;
# Git commit id & info, expected configuration version
-:global CommitId "main/553/53721779";
+:global CommitId "main/554/f4442323";
:global CommitTAG "unknown";
-:global CommitInfo "Autocommit in repo: ros.vados.ru, generated by owner: root, in 12:05:03 04.05.2026.";
+:global CommitInfo "Autocommit in repo: ros.vados.ru, generated by owner: root, in 12:20:03 04.05.2026.";
# The variables are received right here.
:global GlobalConfVersion 140;
}
:local FileName ($DirName . "/" . [ $CleanName $0 ] . "-" . [ $GetRandom20CharAlNum ]);
- :do {
- /tool/fetch check-certificate=$CheckCert url=$fetchUrl dst-path=$FileName \
+ :onerror Err {
+ /tool/fetch check-certificate=$CheckCert $fetchUrl dst-path=$FileName \
http-header-field=({ [ $FetchUserAgentStr $ScriptName ] }) as-value;
- } on-error={
+ } do={
:if ([ $WaitForFile $FileName 500ms ] = true) do={
$RmFile $FileName;
}
- $LogPrint debug $0 ("Failed downloading from " . $fetchUrl . " - " . $Err);
+ :log error ($0 . " Failed downloading from " . $fetchUrl . " - " . $Err);
$RmDir $DirName;
:return false;
}
+
:if ([ $WaitForFile $FileName 5s ] = false) do={
- $LogPrint debug $0 ("The file downloaded from " . $fetchUrl . " did not show up.");
+ :log error ($0 . "The file downloaded from " . $fetchUrl . " did not show up.");
:return false;
}
+
:local FileSize [ /file/get $FileName size ];
:local Return "";
:local VarSize 0;
:delay 100ms;
}
}
- $RmFile $FileName;
+# $RmFile $FileName;
$RmDir $DirName;
:return $Return;
}