HOR-3979
Wrong trigger class registration because of class case sensitive names in PluginsRegistry.
This commit is contained in:
@@ -855,12 +855,19 @@ class PluginRegistry
|
|||||||
}
|
}
|
||||||
if ($found) {
|
if ($found) {
|
||||||
require_once($classFile);
|
require_once($classFile);
|
||||||
$sClassName = substr($this->_aPluginDetails[$trigger->getNamespace()]->getClassName(), 0, 1) .
|
$sClassNameA = substr($this->_aPluginDetails[$trigger->getNamespace()]->getClassName(), 0, 1) .
|
||||||
str_replace(
|
str_replace(
|
||||||
'plugin',
|
['Plugin','plugin'],
|
||||||
|
'Class',
|
||||||
|
substr($this->_aPluginDetails[$trigger->getNamespace()]->getClassName(), 1)
|
||||||
|
);
|
||||||
|
$sClassNameB = substr($this->_aPluginDetails[$trigger->getNamespace()]->getClassName(), 0, 1) .
|
||||||
|
str_replace(
|
||||||
|
['Plugin','plugin'],
|
||||||
'class',
|
'class',
|
||||||
substr($this->_aPluginDetails[$trigger->getNamespace()]->getClassName(), 1)
|
substr($this->_aPluginDetails[$trigger->getNamespace()]->getClassName(), 1)
|
||||||
);
|
);
|
||||||
|
$sClassName = class_exists($sClassNameA) ? $sClassNameA : $sClassNameB;
|
||||||
$obj = new $sClassName();
|
$obj = new $sClassName();
|
||||||
$methodName = $trigger->getTriggerName();
|
$methodName = $trigger->getTriggerName();
|
||||||
$response = $obj->{$methodName}($oData);
|
$response = $obj->{$methodName}($oData);
|
||||||
|
|||||||
Reference in New Issue
Block a user