diff --git a/info.xml b/info.xml index bc9960cc11f5f665c72a75f1c9cc551eefbe8cf4..70183ba66f9109ae828bda51c42fda2112312219 100644 --- a/info.xml +++ b/info.xml @@ -15,9 +15,9 @@ <author>Matthew Wire (MJW Consulting)</author> <email>mjw@mjwconsult.co.uk</email> </maintainer> - <releaseDate>2023-05-01</releaseDate> + <releaseDate>2023-05-31</releaseDate> <version>6.9-dev</version> - <develStage>alpha</develStage> + <develStage>beta</develStage> <compatibility> <ver>5.58</ver> </compatibility> @@ -41,7 +41,7 @@ <mixin>menu-xml@1.0.0</mixin> <mixin>mgd-php@1.0.0</mixin> <mixin>setting-php@1.0.0</mixin> - <mixin>smarty-v2@1.0.0</mixin> + <mixin>smarty-v2@1.0.1</mixin> <mixin>entity-types-php@1.0.0</mixin> </mixins> <upgrader>CRM_Stripe_Upgrader</upgrader> diff --git a/mixin/smarty-v2@1.0.0.mixin.php b/mixin/smarty-v2@1.0.1.mixin.php similarity index 79% rename from mixin/smarty-v2@1.0.0.mixin.php rename to mixin/smarty-v2@1.0.1.mixin.php index 0b371057cce7efb4228c109e2c4aea8e34b24151..5972dbdc57ffd6badbb1eb84f628700ea9727b09 100644 --- a/mixin/smarty-v2@1.0.0.mixin.php +++ b/mixin/smarty-v2@1.0.1.mixin.php @@ -4,7 +4,7 @@ * Auto-register "templates/" folder. * * @mixinName smarty-v2 - * @mixinVersion 1.0.0 + * @mixinVersion 1.0.1 * @since 5.59 * * @param CRM_Extension_MixInfo $mixInfo @@ -19,14 +19,9 @@ return function ($mixInfo, $bootCache) { } $register = function() use ($dir) { - // This implementation is useful for older versions of CiviCRM. It can be replaced/updated going forward (v1.1+). - $smarty = CRM_Core_Smarty::singleton(); - if (!is_array($smarty->template_dir)) { - $this->template_dir = [$smarty->template_dir]; - } - if (!in_array($dir, $smarty->template_dir)) { - array_unshift($smarty->template_dir, $dir); - } + // This implementation has a theoretical edge-case bug on older versions of CiviCRM where a template could + // be registered more than once. + CRM_Core_Smarty::singleton()->addTemplateDir($dir); }; // Let's figure out what environment we're in -- so that we know the best way to call $register(). diff --git a/stripe.civix.php b/stripe.civix.php index 725be6c7970db37c09a3497c31899c0fa5632f79..15253e855d46800329dd579a5a5035db5b58bbfb 100644 --- a/stripe.civix.php +++ b/stripe.civix.php @@ -133,8 +133,8 @@ function _stripe_civix_insert_navigation_menu(&$menu, $path, $item) { if (empty($path)) { $menu[] = [ 'attributes' => array_merge([ - 'label' => CRM_Utils_Array::value('name', $item), - 'active' => 1, + 'label' => $item['name'] ?? NULL, + 'active' => 1, ], $item), ]; return TRUE;