Skip to content
This repository has been archived by the owner on Jan 31, 2020. It is now read-only.

Commit

Permalink
Merge branch 'hotfix/192' into develop
Browse files Browse the repository at this point in the history
Forward port #192
  • Loading branch information
michalbundyra committed Oct 10, 2019
2 parents 9565295 + d3d5900 commit 1e0bc98
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 3 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,9 @@ All notable changes to this project will be documented in this file, in reverse

### Fixed

- Nothing.
- [#192](https://github.com/zendframework/zend-view/pull/192) changes
curly braces in array and string offset access to square brackets
in order to prevent issues under the upcoming PHP 7.4 release.

## 2.11.2 - 2019-02-19

Expand Down
4 changes: 2 additions & 2 deletions src/Helper/Navigation/Sitemap.php
Original file line number Diff line number Diff line change
Expand Up @@ -267,10 +267,10 @@ public function url(AbstractPage $page)
{
$href = $page->getHref();

if (! isset($href{0})) {
if (! isset($href[0])) {
// no href
return '';
} elseif ($href{0} == '/') {
} elseif ($href[0] == '/') {
// href is relative to root; use serverUrl helper
$url = $this->getServerUrl() . $href;
} elseif (preg_match('/^[a-z]+:/im', (string) $href)) {
Expand Down

0 comments on commit 1e0bc98

Please sign in to comment.