From 6ea06b7620a37fd28638d73ad5f0c531fed07a2e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Munsch?= Date: Wed, 25 Aug 2021 14:39:47 +0200 Subject: [PATCH] Fix WPCRM saveOrUpdateUserToTable --- src/WordPress/WPCrm.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/WordPress/WPCrm.php b/src/WordPress/WPCrm.php index f362020..4d86310 100644 --- a/src/WordPress/WPCrm.php +++ b/src/WordPress/WPCrm.php @@ -536,7 +536,7 @@ class WPCrm */ private static function saveOrUpdateUserToTable() { - if (self::getUserFromTable(self::$user->hashcode)) { + if (is_string(self::$user->hashcode) and self::getUserFromTable(self::$user->hashcode)) { self::query( 'UPDATE `ldc_wp_customers` SET `email` = %s, `uuid` = %s WHERE `hashcode` = %s', [