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:
e804f45
)
Fix bug 2095: three closing brackets
author
Gabriel Wicke
<gwicke@users.mediawiki.org>
Fri, 24 Mar 2006 16:40:31 +0000
(16:40 +0000)
committer
Gabriel Wicke
<gwicke@users.mediawiki.org>
Fri, 24 Mar 2006 16:40:31 +0000
(16:40 +0000)
includes/Parser.php
patch
|
blob
|
history
diff --git
a/includes/Parser.php
b/includes/Parser.php
index
33bfadf
..
1c8eca9
100644
(file)
--- a/
includes/Parser.php
+++ b/
includes/Parser.php
@@
-1407,7
+1407,11
@@
class Parser
# Still some problems for cases where the ] is meant to be outside punctuation,
# and no image is in sight. See bug 2095.
#
- if( $text !== '' && preg_match( "/^\](.*)/s", $m[3], $n ) ) {
+ if( $text !== '' &&
+ preg_match( "/^\](.*)/s", $m[3], $n ) &&
+ strpos($text, '[') !== false
+ )
+ {
$text .= ']'; # so that replaceExternalLinks($text) works later
$m[3] = $n[1];
}