Skip to content

Commit

Permalink
[TASK] Fix method return in Nimut\Hellurl\UriGeneratorAndResolver
Browse files Browse the repository at this point in the history
  • Loading branch information
IchHabRecht committed Jan 23, 2017
1 parent 9e3c471 commit defe8ef
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions Classes/UriGeneratorAndResolver.php
Original file line number Diff line number Diff line change
Expand Up @@ -946,17 +946,15 @@ protected function fetchPagesForPath($url)
* @param int $startPid Page id in which to search subpages matching first part of urlParts
* @param string $mpvar MP variable string
* @param array $urlParts Segments of the virtual path (passed by reference; items removed)
* @param array|string $currentIdMp Array with the current pid/mpvar to return if no processing is done.
* @param array|null $currentIdMp Array with the current pid/mpvar to return if no processing is done.
* @param bool $foundUID
*
* @return array With resolved id and $mpvar
*/
protected function findIDBySegment($startPid, $mpvar, array &$urlParts, $currentIdMp = '', $foundUID = false)
protected function findIDBySegment($startPid, $mpvar, array &$urlParts, $currentIdMp = null, $foundUID = false)
{
// Creating currentIdMp variable if not set
if (!is_array($currentIdMp)) {
$currentIdMp = array($startPid, $mpvar, $foundUID);
}
$currentIdMp = ($currentIdMp !== null) ? $currentIdMp : array($startPid, $mpvar, $foundUID);

// No more urlparts? Return what we have.
if (count($urlParts) == 0) {
Expand Down

0 comments on commit defe8ef

Please sign in to comment.