qlink: Allow passing null as default for $properties
This commit is contained in:
parent
04d2c78983
commit
f6ea02fec5
|
@ -27,8 +27,8 @@ $this->addHelperFunction('url', function ($path = null, $params = null) {
|
||||||
return $url;
|
return $url;
|
||||||
});
|
});
|
||||||
|
|
||||||
$this->addHelperFunction('qlink', function ($title, $url, $params = null, $properties = array(), $escape = true) use ($view) {
|
$this->addHelperFunction('qlink', function ($title, $url, $params = null, $properties = null, $escape = true) use ($view) {
|
||||||
if (array_key_exists('title', $properties) && !array_key_exists('aria-label', $properties)) {
|
if ($properties && array_key_exists('title', $properties) && !array_key_exists('aria-label', $properties)) {
|
||||||
$properties['aria-label'] = $properties['title'];
|
$properties['aria-label'] = $properties['title'];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue