Wrong autoload template registry file path in Web Asset Registry
Steps to reproduce the issue
Change "administrator" folder in "/includes/defines.php" and "/administrator/includes/defines.php" to "admin" rename "administrator" folder to "admin"
Expected result
Everything working
Actual result
Error 500 - There is no "template.atum.ltr" asset of a "preset" type in the registry.
System information (as much as possible)
Joomla 5.x
Additional comments
Change "addTemplateRegistryFile" function in /libraries/src/WebAsset/WebAssetRegistry.php to:
/**
* Helper method to register new file with Template Asset(s) info
*
* @param string $template The template name
* @param integer $client The application client id
*
* @return self
*
* @since 4.0.0
*/
public function addTemplateRegistryFile(string $template, int $client): self
{
switch ($client) {
case 0:
case 1:
$this->addRegistryFile(str_replace(JPATH_ROOT . '/', '', JPATH_THEMES) . '/' . $template . '/joomla.asset.json');
break;
default:
break;
}
return $this;
}
Fix for issue... Rename to php WebAssetRegistry.txt
@pinta83 If the issue is fixed it should be closed.
It's not fixed, I only offered a solution. Still needs to be implemented / merged with Joomla... I tried to do a pull request, but sadly I can't - since I'm not a contributor (anymore).
I tried to do a pull request, but sadly I can't - since I'm not a contributor (anymore).
Anyone can make a pull request https://docs.joomla.org/Using_the_Github_UI_to_Make_Pull_Requests
@Fedik Could you please look at this when you have a moment? Thanks.
Please test https://github.com/joomla/joomla-cms/pull/44980