From 9cec4195124c96e609f14b38a4dbfd0a69488030 Mon Sep 17 00:00:00 2001 From: Seamus Lee Date: Wed, 31 May 2017 08:15:10 +1000 Subject: [PATCH] CRM-20662 Ensure that the system only tries populating the domain_id field if there is only 1 domain in the system --- CRM/Upgrade/Incremental/php/FourSeven.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CRM/Upgrade/Incremental/php/FourSeven.php b/CRM/Upgrade/Incremental/php/FourSeven.php index c3f9319287ad..aea404fd539b 100644 --- a/CRM/Upgrade/Incremental/php/FourSeven.php +++ b/CRM/Upgrade/Incremental/php/FourSeven.php @@ -1094,7 +1094,7 @@ public static function deprecateStateProvinces($countryID, $provinces) { */ public static function populateSMSProviderDomainId() { $count = CRM_Core_DAO::singleValueQuery("SELECT count(id) FROM civicrm_domain"); - if ($count = 1) { + if ($count == 1) { CRM_Core_DAO::executeQuery("UPDATE civicrm_sms_provider SET domain_id = (SELECT id FROM civicrm_domain)"); } if (!parent::checkFKExists('civicrm_sms_provider', 'FK_civicrm_sms_provider_domain_id')) {