#71585Wrong condition at resolving of controller action name
Description
It seems for me like the name of a controller Action written in lowerCamelCase like “SomeSuperDesignedAction” will not be resolved, because of the check in this function.
If the controller action is called without arguments, there’s no problem. Otherwise the method argument validation can not be mapped.
I think the it should be if ($controllerObjectName !== '' && $this->controllerActionName !== strtolower($this->controllerActionName)){...}
/**
* Returns the name of the action the controller is supposed to execute.
*
* @return string Action name
* @api
*/
public function getControllerActionName() {
$controllerObjectName = $this->getControllerObjectName();
if ($controllerObjectName !== '' && $this->controllerActionName === strtolower($this->controllerActionName)) {
$actionMethodName = $this->controllerActionName . 'Action';
$classMethods = get_class_methods($controllerObjectName);
if (is_array($classMethods)) {
foreach ($classMethods as $existingMethodName) {
if (strtolower($existingMethodName) === strtolower($actionMethodName)) {
$this->controllerActionName = substr($existingMethodName, 0, -6);
break;
}
}
}
}
return $this->controllerActionName;
}
typo3.png
Reviews 0
No change resolves or names this issue in its commit message, and no comment links one.