* Optimize the function executeHooks.
This commit is contained in:
@@ -26,7 +26,7 @@ class build extends control
|
||||
if(dao::isError()) $this->send(array('result' => 'fail', 'message' => dao::getError()));
|
||||
$this->loadModel('action')->create('build', $buildID, 'opened');
|
||||
|
||||
$this->executeHooks($this->methodName, $buildID);
|
||||
$this->executeHooks($buildID);
|
||||
|
||||
if(isonlybody()) $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'closeModal' => true, 'callback' => "parent.loadProjectBuilds($projectID)"));//Code for task #5126.
|
||||
$this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'locate' => $this->createLink('build', 'view', "buildID=$buildID")));
|
||||
@@ -108,7 +108,7 @@ class build extends control
|
||||
if(!empty($changes)) $this->action->logHistory($actionID, $changes);
|
||||
}
|
||||
|
||||
$this->executeHooks($this->methodName, $buildID);
|
||||
$this->executeHooks($buildID);
|
||||
|
||||
$this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'locate' => inlink('view', "buildID=$buildID")));
|
||||
}
|
||||
@@ -230,7 +230,7 @@ class build extends control
|
||||
$this->view->type = $type;
|
||||
}
|
||||
|
||||
$this->executeHooks($this->methodName, $buildID);
|
||||
$this->executeHooks($buildID);
|
||||
|
||||
/* Assign. */
|
||||
$this->view->users = $this->loadModel('user')->getPairs('noletter');
|
||||
@@ -263,7 +263,7 @@ class build extends control
|
||||
$build = $this->build->getById($buildID);
|
||||
$this->build->delete(TABLE_BUILD, $buildID);
|
||||
|
||||
$this->executeHooks($this->methodName, $buildID);
|
||||
$this->executeHooks($buildID);
|
||||
|
||||
/* if ajax request, send result. */
|
||||
if($this->server->ajax)
|
||||
|
||||
Reference in New Issue
Block a user