Page Menu
Home
WickedGov Phorge
Search
Configure Global Search
Log In
Files
F1430370
BaseMaintenanceScript.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
859 B
Referenced Files
None
Subscribers
None
BaseMaintenanceScript.php
View Options
<?php
declare
(
strict_types
=
1
);
namespace
MediaWiki\Extension\Translate\Utilities
;
use
Maintenance
;
/**
* Base maintenance script containing constants and methods used in multiple scripts
* Hopefully the constants can be removed after https://phabricator.wikimedia.org/T271787 is fixed.
* @author Niklas Laxström
* @license GPL-2.0-or-later
*/
abstract
class
BaseMaintenanceScript
extends
Maintenance
{
protected
const
OPTIONAL
=
false
;
protected
const
REQUIRED
=
true
;
protected
const
HAS_ARG
=
true
;
protected
const
NO_ARG
=
false
;
/**
* Converts a comma seperated list to an array. Removes empty strings and duplicate values.
* @return string[]
*/
protected
static
function
commaList2Array
(
string
$list
):
array
{
return
array_unique
(
array_filter
(
array_map
(
'trim'
,
explode
(
','
,
$list
)
),
'strlen'
)
);
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Sat, May 16, 18:40 (5 h, 45 m)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
0a/18/c2a270ecd7c72f6a78e07176794c
Default Alt Text
BaseMaintenanceScript.php (859 B)
Attached To
Mode
rMWPROD MediaWiki Production
Attached
Detach File
Event Timeline
Log In to Comment