Merge "Remove unreachable parts of getTitleInvalidRegex() in PHP and JS"
This commit is contained in:
commit
c648896ab7
4 changed files with 1 additions and 11 deletions
|
|
@ -599,8 +599,6 @@ class MediaWikiTitleCodec implements TitleFormatter, TitleParser {
|
|||
'|%[0-9A-Fa-f]{2}' .
|
||||
# XML/HTML character references produce similar issues.
|
||||
'|&[A-Za-z0-9\x80-\xff]+;' .
|
||||
'|&#[0-9]+;' .
|
||||
'|&#x[0-9A-Fa-f]+;' .
|
||||
'/S';
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -148,9 +148,7 @@ var toUpperMap,
|
|||
// to round-trip titles -- you can't link to them consistently.
|
||||
'|%[\\dA-Fa-f]{2}' +
|
||||
// XML/HTML character references produce similar issues.
|
||||
'|&[\\dA-Za-z\u0080-\uFFFF]+;' +
|
||||
'|&#\\d+;' +
|
||||
'|&#x[\\dA-Fa-f]+;'
|
||||
'|&[\\dA-Za-z\u0080-\uFFFF]+;'
|
||||
),
|
||||
|
||||
// From MediaWikiTitleCodec::splitTitleString() in PHP
|
||||
|
|
|
|||
|
|
@ -822,8 +822,6 @@ class TitleTest extends MediaWikiIntegrationTestCase {
|
|||
// Note: Commented out because they are not marked invalid by the PHP test as
|
||||
// Title::newFromText runs Sanitizer::decodeCharReferencesAndNormalize first.
|
||||
// 'A é B',
|
||||
// 'A é B',
|
||||
// 'A é B',
|
||||
// Subject of NS_TALK does not roundtrip to NS_MAIN
|
||||
[ 'Talk:File:Example.svg', 'title-invalid-talk-namespace' ],
|
||||
// Directory navigation
|
||||
|
|
|
|||
|
|
@ -45,11 +45,7 @@
|
|||
'A%23B',
|
||||
'A%2523B',
|
||||
// XML/HTML character entity references
|
||||
// Note: The ones with # are commented out as those are interpreted as fragment and
|
||||
// as such end up being valid.
|
||||
'A é B',
|
||||
// 'A é B',
|
||||
// 'A é B',
|
||||
// Subject of NS_TALK does not roundtrip to NS_MAIN
|
||||
'Talk:File:Example.svg',
|
||||
// Directory navigation
|
||||
|
|
|
|||
Loading…
Reference in a new issue