Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
20.00% covered (danger)
20.00%
1 / 5
50.00% covered (danger)
50.00%
1 / 2
CRAP
0.00% covered (danger)
0.00%
0 / 1
SpecialSkinDistributor
20.00% covered (danger)
20.00%
1 / 5
50.00% covered (danger)
50.00%
1 / 2
12.19
0.00% covered (danger)
0.00%
0 / 1
 __construct
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 getPopularList
0.00% covered (danger)
0.00%
0 / 4
0.00% covered (danger)
0.00%
0 / 1
12
1<?php
2
3namespace MediaWiki\Extension\ExtensionDistributor\Specials;
4
5use MediaWiki\Extension\ExtensionDistributor\Providers\ExtDistProvider;
6use Wikimedia\Stats\IBufferingStatsdDataFactory;
7
8/**
9 * Special page that allows users to download skins as tar archives.
10 *
11 * @author Legoktm
12 */
13class SpecialSkinDistributor extends SpecialBaseDistributor {
14
15    /** @var string */
16    protected $type = ExtDistProvider::SKINS;
17
18    /**
19     * @param IBufferingStatsdDataFactory $statsFactory
20     */
21    public function __construct( IBufferingStatsdDataFactory $statsFactory ) {
22        parent::__construct( 'SkinDistributor', $statsFactory );
23    }
24
25    /** @inheritDoc */
26    protected function getPopularList() {
27        $list = parent::getPopularList();
28        if ( $list ) {
29            return $list;
30        }
31
32        return $this->getConfig()->get( 'ExtDistPopularSkinList' ) ?: false;
33    }
34}