function () {
if (!isSet($this->failureHandler)) {
$newReq = $this->requestData; //makes a copy
$handlerOrigin = isSet($newReq['pntHandlerOrigin']) ? $newReq['pntHandlerOrigin'] : null;
$newReq['pntHandler'] = $handlerOrigin ? $handlerOrigin : 'EditDetailsPage';
$obj = $this->object;
if ($this->copy) {
//make request different from create new
if ($this->object->()) {
//only happens if called from finishFailure
//restore id and object
$newReq['id'] = $this->requestData['pntOriginalId'];
$obj = $this->original;
} else {
$newReq['id'] = $this->object->('id');
}
}
$this->failureHandler = $this->($newReq);
$this->failureHandler->($this->());
$this->failureHandler->($obj);
}
return $this->failureHandler;
}
|