From c00378d73afd99f2494e077577b49540e969f6f3 Mon Sep 17 00:00:00 2001 From: John Twyman Date: Tue, 10 Aug 2021 16:48:00 +1000 Subject: [PATCH] Fix the check to see if the financialAclExtension is installed --- CRM/Upgrade/Incremental/General.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CRM/Upgrade/Incremental/General.php b/CRM/Upgrade/Incremental/General.php index 115e47a7d01e..9023a670c800 100644 --- a/CRM/Upgrade/Incremental/General.php +++ b/CRM/Upgrade/Incremental/General.php @@ -122,8 +122,8 @@ public static function setPreUpgradeMessage(&$preUpgradeMessage, $currentVer, $l } $ftAclSetting = Civi::settings()->get('acl_financial_type'); - $financialAclExtension = civicrm_api3('extension', 'get', ['key' => 'biz.jmaconsulting.financialaclreport']); - if ($ftAclSetting && (($financialAclExtension['count'] == 1 && $financialAclExtension['status'] != 'Installed') || $financialAclExtension['count'] !== 1)) { + $financialAclExtension = civicrm_api3('extension', 'get', ['key' => 'biz.jmaconsulting.financialaclreport', 'sequential' => 1]); + if ($ftAclSetting && (($financialAclExtension['count'] == 1 && $financialAclExtension['values'][0]['status'] != 'Installed') || $financialAclExtension['count'] !== 1)) { $preUpgradeMessage .= '
' . ts('CiviCRM will in the future require the extension %1 for CiviCRM Reports to work correctly with the Financial Type ACLs. The extension can be downloaded here', [ 1 => 'biz.jmaconsulting.financialaclreport', 2 => 'https://github.com/JMAConsulting/biz.jmaconsulting.financialaclreport',