From 9dc6618d23639a083cc84ef1538cb21d510a6f58 Mon Sep 17 00:00:00 2001 From: jhartworks Date: Thu, 16 Apr 2026 13:59:51 +0200 Subject: [PATCH] fix: correct base64 encoding usage for projectId and clientId in SQL queries --- CounterServer/module.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/CounterServer/module.php b/CounterServer/module.php index 4f3931a..86975c5 100644 --- a/CounterServer/module.php +++ b/CounterServer/module.php @@ -72,8 +72,9 @@ class CounterServer extends IPSModule VALUES ( " . $this->esc($projectId) . "', - '" . $this->esc(base64_encode($projectId.$clientId . '_' . $counterId)) . "', '" . $this->esc($counterId) . "', + '" . $this->base64_encode($projectId.$clientId . '_' . $counterId). "', + '" . $this->esc($clientId) . "', '" . $this->esc($clientName) . "', '" . $this->esc($type) . "', @@ -94,7 +95,7 @@ class CounterServer extends IPSModule // ---------- GET meter_id ---------- $sqlGet = " SELECT id FROM meter_devices - WHERE meter_uuid = '" . $this->esc(base64_encode($projectId.$clientId . '_' . $counterId)) . "' + WHERE meter_uuid = '" . $this->base64_encode($projectId.$clientId . '_' . $counterId). "' LIMIT 1 ";