From 58aeead326b21b17fd056331b858e78c75a14f9d Mon Sep 17 00:00:00 2001 From: Lars Gebhardt-Kusche Date: Tue, 3 Feb 2026 00:28:02 +0100 Subject: [PATCH] Debug --- config/current.ver | 2 +- src/ApiKernel.php | 11 +++++++++++ 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/config/current.ver b/config/current.ver index 05060b8..a96f385 100644 --- a/config/current.ver +++ b/config/current.ver @@ -1 +1 @@ -1.2.15 \ No newline at end of file +1.2.16 \ No newline at end of file diff --git a/src/ApiKernel.php b/src/ApiKernel.php index f2c1049..c8049c1 100644 --- a/src/ApiKernel.php +++ b/src/ApiKernel.php @@ -4917,6 +4917,17 @@ SQL; $file = rtrim($dir, '/') . '/' . $safeName . '.log'; $data = json_encode($payload, JSON_UNESCAPED_UNICODE | JSON_UNESCAPED_SLASHES | JSON_PRETTY_PRINT); @file_put_contents($file, $data ?: ''); + + $fallback = sys_get_temp_dir() . '/emailtemplate_debug.log'; + $line = json_encode([ + 'time' => date(DATE_ATOM), + 'name' => $safeName, + 'file' => $file, + 'wrote_bytes' => is_string($data) ? strlen($data) : 0, + 'dir_exists' => is_dir($dir), + 'dir_writable' => is_writable($dir), + ], JSON_UNESCAPED_UNICODE | JSON_UNESCAPED_SLASHES); + @file_put_contents($fallback, ($line ?: '') . "\n", FILE_APPEND); } private function defaultApiBase(): string