Page Menu
Home
WickedGov Phorge
Search
Configure Global Search
Log In
Files
F1432870
EnConverter.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
735 B
Referenced Files
None
Subscribers
None
EnConverter.php
View Options
<?php
declare
(
strict_types
=
1
);
namespace
Wikimedia\Parsoid\Language
;
use
Wikimedia\LangConv\FstReplacementMachine
;
class
EnConverter
extends
LanguageConverter
{
public
function
loadDefaultTables
()
{
$this
->
setMachine
(
new
FstReplacementMachine
(
'en'
,
[
'en'
,
'en-x-piglatin'
]
)
);
}
// phpcs:ignore MediaWiki.Commenting.FunctionComment.MissingDocumentationPublic
public
function
findVariantLink
(
$link
,
$nt
,
$ignoreOtherCond
)
{
$ns
=
$nt
->
getNamespace
();
// do not try to find variants for usernames
if
(
$ns
->
isUser
()
||
$ns
->
isUserTalk
)
{
return
[
'nt'
=>
$nt
,
'link'
=>
$link
];
}
// FIXME check whether selected language is 'en'
return
parent
::
findVariantLink
(
$link
,
$nt
,
$ignoreOtherCond
);
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Sat, May 16, 22:25 (1 d, 1 h)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
cf/dc/32d65f0ed7346b6bfe9d83418789
Default Alt Text
EnConverter.php (735 B)
Attached To
Mode
rMWPROD MediaWiki Production
Attached
Detach File
Event Timeline
Log In to Comment