From 2d2374fb0c9732edd3fe3b8639f8fe1c37c2396c Mon Sep 17 00:00:00 2001 From: Damien Carreno <86370894+Axiome974@users.noreply.github.com> Date: Thu, 30 Apr 2026 17:13:13 +0400 Subject: [PATCH] Fix getID method to handle null values and always return a string getID() should always return a string, but in some cases it returns an integer. --- src/Resource/AbstractResource.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Resource/AbstractResource.php b/src/Resource/AbstractResource.php index 5704c5c..8a36b40 100644 --- a/src/Resource/AbstractResource.php +++ b/src/Resource/AbstractResource.php @@ -177,7 +177,8 @@ public function clearUnsavedValues() */ public function getID() { - return $this->getValue('id'); + $value = $this->getValue('id'); + return $value === null ? null : (string) $value; } /**