From 65cac4c6e2b93bc85714e025d96497a6a37a3e3b Mon Sep 17 00:00:00 2001 From: Clemens Schwaighofer Date: Fri, 2 Jun 2023 17:45:21 +0900 Subject: [PATCH] Logging bug fixes for per_date/per_run flags --- src/Logging/Logging.php | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/Logging/Logging.php b/src/Logging/Logging.php index 06a4aaf..44e4d3b 100644 --- a/src/Logging/Logging.php +++ b/src/Logging/Logging.php @@ -407,13 +407,6 @@ class Logging } $this->setLogFlag($log_flag_key); } - // init per run uid - if ($this->getLogFlag(Flag::per_run)) { - $this->setLogUniqueId(); - } elseif ($this->getLogFlag(Flag::per_date)) { - // init file date - $this->log_file_date = date('Y-m-d'); - } } /** @@ -776,6 +769,13 @@ class Logging public function setLogFlag(Flag $flag): void { $this->log_flags |= $flag->value; + // init per run uid + if ($this->getLogFlag(Flag::per_run)) { + $this->setLogUniqueId(); + } elseif ($this->getLogFlag(Flag::per_date)) { + // init file date + $this->setLogDate(); + } } /**