Skip to content

Commit

Permalink
Fix
Browse files Browse the repository at this point in the history
  • Loading branch information
javiereguiluz committed Nov 7, 2015
1 parent bd02235 commit c2dea9e
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Controller/AdminController.php
Expand Up @@ -693,15 +693,15 @@ private function isPostgreSqlUsedByEntity($entityClass)
* does not exist, it executes the regular method.
*
* For example:
* executeDynamicMethod('create<EntityName>Entity') and $this->entity['name'] = 'User'
* executeDynamicMethod('create<EntityName>Entity') and the entity name is 'User'
* if 'createUserEntity()' exists, execute it; otherwise execute 'createEntity()'
*
* @param string $methodName The name of the method (enclsoing dynamic parts with <> angle brackets)
* @param array $arguments The arguments passed to the executed method
* @param string $methodNamePattern The pattern of the method name (dynamic parts are enclosed with <> angle brackets)
* @param array $arguments The arguments passed to the executed method
*
* @return mixed
*/
private function executeDynamicMethod($methodName, array $arguments = array())
private function executeDynamicMethod($methodNamePattern, array $arguments = array())
{
$methodName = str_replace('<EntityName>', $this->entity['name'], $methodNamePattern);
if (!method_exists($this, $methodName)) {
Expand Down

0 comments on commit c2dea9e

Please sign in to comment.