From 3a8ead876000f69da472fecc3b8247da8565ff46 Mon Sep 17 00:00:00 2001
From: Thibault Dockx <thibault.dockx@fusiondirectory.org>
Date: Tue, 24 Oct 2023 16:05:54 +0100
Subject: [PATCH] :ambulance: Feat(TASKS) - phpcs e phpstan

Fixes phpcs and phpstan.
---
 plugins/configuration/tasks/class_tasksMail.inc | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/plugins/configuration/tasks/class_tasksMail.inc b/plugins/configuration/tasks/class_tasksMail.inc
index 872cca03c..cb8781118 100644
--- a/plugins/configuration/tasks/class_tasksMail.inc
+++ b/plugins/configuration/tasks/class_tasksMail.inc
@@ -293,7 +293,8 @@ class tasksMail extends simplePlugin
         $tabObject = objects::create('TasksGranular');
 
         // Create a unique ID based on timestamp (Allowing duplicate subtasks for same members in case of repeat).
-        $timestamp = microtime(true);  // Get the current timestamp with microseconds
+        $timestamp = microtime(TRUE);  // Get the current timestamp with microseconds
+        $timestamp = (string)$timestamp; // Convert the float to a string, str_replace expect array or string.
         $uniqueID = str_replace(".", "_", $timestamp); // Remove . with _ for correct CN
 
         // Array matches come from preg_match function above with rmDn
-- 
GitLab