dépôts
/
lhc
/
web
/
wiklou.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f73473a
)
Param &$html for the "LinkBegin" hook needs to be null if $text is null
author
Marius Hoch
<hoo@online.de>
Wed, 25 May 2016 19:25:12 +0000
(21:25 +0200)
committer
Marius Hoch
<hoo@online.de>
Wed, 25 May 2016 19:25:12 +0000
(21:25 +0200)
To keep b/c with the old implementation.
Change-Id: I5fff92f47babe890fe0d3726dba6f60cc75ee708
includes/linker/LinkRenderer.php
patch
|
blob
|
history
diff --git
a/includes/linker/LinkRenderer.php
b/includes/linker/LinkRenderer.php
index
0261365
..
cb3acce
100644
(file)
--- a/
includes/linker/LinkRenderer.php
+++ b/
includes/linker/LinkRenderer.php
@@
-213,7
+213,11
@@
class LinkRenderer {
$ret = null;
$dummy = new DummyLinker();
$title = Title::newFromLinkTarget( $target );
- $realHtml = $html = HtmlArmor::getHtml( $text );
+ if ( $text !== null ) {
+ $realHtml = $html = HtmlArmor::getHtml( $text );
+ } else {
+ $realHtml = $html = null;
+ }
if ( !Hooks::run( 'LinkBegin',
[ $dummy, $title, &$html, &$extraAttribs, &$query, &$options, &$ret ] )
) {