@@ 176-186 (lines=11) @@ | ||
173 | ||
174 | $current = $keys[$routeIndex]; |
|
175 | $previous = null; |
|
176 | for ($i = $current - 1; $i >= 0; $i--) { |
|
177 | $isSectionHeader = $values[$i]["sectionHeader"]; |
|
178 | $isLinkable = $values[$i]["linkable"]; // ?? null; |
|
179 | $isInternal = $values[$i]["internal"]; |
|
180 | if (($isSectionHeader && !$isLinkable) || $isInternal) { |
|
181 | continue; |
|
182 | } |
|
183 | $previous = $values[$i]; |
|
184 | $previous["route"] = $index2Key[$i]; |
|
185 | break; |
|
186 | } |
|
187 | ||
188 | $next = null; |
|
189 | for ($i = $current + 1; $i < $count; $i++) { |
|
@@ 189-199 (lines=11) @@ | ||
186 | } |
|
187 | ||
188 | $next = null; |
|
189 | for ($i = $current + 1; $i < $count; $i++) { |
|
190 | $isSectionHeader = $values[$i]["sectionHeader"]; |
|
191 | $isLinkable = $values[$i]["linkable"]; // ?? null; |
|
192 | $isInternal = $values[$i]["internal"]; |
|
193 | if (($isSectionHeader && !$isLinkable) || $isInternal) { |
|
194 | continue; |
|
195 | } |
|
196 | $next = $values[$i]; |
|
197 | $next["route"] = $index2Key[$i]; |
|
198 | break; |
|
199 | } |
|
200 | ||
201 | return [$next, $previous]; |
|
202 | } |