33
2
mirror of https://github.com/joomla-extensions/jedchecker.git synced 2024-11-12 00:06:27 +00:00

fix matching of plugin group in title (remove spaces for "Action Log", "Quick Icons", etc.)

This commit is contained in:
Denis Ryabov 2021-02-18 15:24:28 +03:00
parent e833785494
commit f536d77cc3

View File

@ -219,8 +219,9 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule
if ($type === 'plugin')
{
$group = (string) $xml['group'];
if (strpos($extension_name, ucfirst($group) . ' - ') !== 0)
$parts = explode(' - ', $extension_name, 2);
$extension_name_group = isset($parts[1]) ? strtolower(preg_replace('/\s/', '', $parts[0])) : false;
if ($extension_name_group !== (string) $xml['group'])
{
$this->report->addWarning($file, JText::_('COM_JEDCHECKER_INFO_XML_NAME_PLUGIN_FORMAT'));
}