|
@@ 278-288 (lines=11) @@
|
| 275 |
|
* @return array|bool |
| 276 |
|
* @throws \Exception |
| 277 |
|
*/ |
| 278 |
|
public function isClosureAndTemplate($callback) |
| 279 |
|
{ |
| 280 |
|
if (is_array($cls = $this->isClosure($callback))) { |
| 281 |
|
if (is_array($this->request['params']) && isset($this->request['params']['template']) && is_array($tpl = $this->isTemplate($this->request['params']['template']))) { |
| 282 |
|
return array_merge(array_merge($cls, $tpl), [ |
| 283 |
|
'dispatcher' => $this->dispatcher['isClosureAndTemplate'] |
| 284 |
|
]); |
| 285 |
|
} |
| 286 |
|
return $cls; |
| 287 |
|
} |
| 288 |
|
return false; |
| 289 |
|
} |
| 290 |
|
|
| 291 |
|
/** |
|
@@ 296-306 (lines=11) @@
|
| 293 |
|
* @return array|bool |
| 294 |
|
* @throws \Exception |
| 295 |
|
*/ |
| 296 |
|
public function isControllerAndTemplate($callback) |
| 297 |
|
{ |
| 298 |
|
if (is_array($ctrl = $this->isController($callback))) { |
| 299 |
|
if (is_array($this->request['params']) && isset($this->request['params']['template']) && is_array($tpl = $this->isTemplate($this->request['params']['template']))) { |
| 300 |
|
return array_merge(array_merge($ctrl, $tpl), [ |
| 301 |
|
'dispatcher' => $this->dispatcher['isControllerAndTemplate'] |
| 302 |
|
]); |
| 303 |
|
} |
| 304 |
|
return $ctrl; |
| 305 |
|
} |
| 306 |
|
return false; |
| 307 |
|
} |
| 308 |
|
|
| 309 |
|
|