Skip to content
Snippets Groups Projects
Commit f88b85fd authored by mattwire's avatar mattwire
Browse files

Release 1.4

parent 5fdc4d8b
No related branches found
No related tags found
No related merge requests found
......@@ -27,6 +27,10 @@ See: https://docs.civicrm.org/sysadmin/en/latest/customize/extensions/#installin
## Release Notes
### 1.4 (2023-12-10)
* Update User create to defer to CMS for password / notify.
### 1.3.1 (2023-12-07)
* Replace deprecated functions.
......
......@@ -13,12 +13,15 @@
<url desc="Support">https://mjw.pt/support/cmsuser</url>
<url desc="Licensing">http://www.gnu.org/licenses/agpl-3.0.html</url>
</urls>
<releaseDate>2023-12-07</releaseDate>
<version>1.3.1</version>
<releaseDate>2023-12-10</releaseDate>
<version>1.4</version>
<develStage>stable</develStage>
<compatibility>
<ver>5.58</ver>
<ver>5.65</ver>
</compatibility>
<requires>
<ext>org.civicoop.civirules</ext>
</requires>
<classloader>
<psr0 prefix="CRM_" path="."/>
<psr4 prefix="Civi\" path="Civi"/>
......
<?php
/**
* Auto-register "templates/" folder.
*
* @mixinName smarty-v2
* @mixinVersion 1.0.1
* @since 5.59
*
* @param CRM_Extension_MixInfo $mixInfo
* On newer deployments, this will be an instance of MixInfo. On older deployments, Civix may polyfill with a work-a-like.
* @param \CRM_Extension_BootCache $bootCache
* On newer deployments, this will be an instance of MixInfo. On older deployments, Civix may polyfill with a work-a-like.
*/
return function ($mixInfo, $bootCache) {
$dir = $mixInfo->getPath('templates');
if (!file_exists($dir)) {
return;
}
$register = function() use ($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().
if (!empty($GLOBALS['_CIVIX_MIXIN_POLYFILL'])) {
// Polyfill Loader (v<=5.45): We're already in the middle of firing `hook_config`.
if ($mixInfo->isActive()) {
$register();
}
return;
}
if (CRM_Extension_System::singleton()->getManager()->extensionIsBeingInstalledOrEnabled($mixInfo->longName)) {
// New Install, Standard Loader: The extension has just been enabled, and we're now setting it up.
// System has already booted. New templates may be needed for upcoming installation steps.
$register();
return;
}
// Typical Pageview, Standard Loader: Defer the actual registration for a moment -- to ensure that Smarty is online.
\Civi::dispatcher()->addListener('hook_civicrm_config', function() use ($mixInfo, $register) {
if ($mixInfo->isActive()) {
$register();
}
});
};
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment