aboutsummaryrefslogtreecommitdiffstats
path: root/global-functions
diff options
context:
space:
mode:
Diffstat (limited to 'global-functions')
-rw-r--r--global-functions6
1 files changed, 6 insertions, 0 deletions
diff --git a/global-functions b/global-functions
index 51c87bc..713a284 100644
--- a/global-functions
+++ b/global-functions
@@ -344,10 +344,16 @@
:global EitherOr;
:global LogPrintExit2;
+ :global TimeIsSync;
:local AllDone true;
:local QueueLen [ :len $EmailQueue ];
+ :if ([ $TimeIsSync ] = false) do={
+ $LogPrintExit2 debug $0 ("Time is not synced, not flushing.") false;
+ :return false;
+ }
+
:if ([ :len [ /system/scheduler/find where name="FlushEmailQueue" ] ] > 0 && $QueueLen = 0) do={
$LogPrintExit2 warning $0 ("Flushing E-Mail messages from scheduler, but queue is empty.") false;
}