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:
0b06c86
)
Fix language code validation regex to allow be-x-old.
author
Tim Starling
<tstarling@users.mediawiki.org>
Mon, 2 Apr 2007 17:49:12 +0000
(17:49 +0000)
committer
Tim Starling
<tstarling@users.mediawiki.org>
Mon, 2 Apr 2007 17:49:12 +0000
(17:49 +0000)
includes/StubObject.php
patch
|
blob
|
history
diff --git
a/includes/StubObject.php
b/includes/StubObject.php
index
4035f1b
..
894550c
100644
(file)
--- a/
includes/StubObject.php
+++ b/
includes/StubObject.php
@@
-100,7
+100,8
@@
class StubUserLang extends StubObject {
}
# Validate $code
- if( empty( $code ) || !preg_match( '/^[a-z]+(-[a-z]+)?$/', $code ) ) {
+ if( empty( $code ) || !preg_match( '/^[a-z-]+$/', $code ) ) {
+ wfDebug( "Invalid user language code\n" );
$code = $wgContLanguageCode;
}