dépôts
/
lhc
/
web
/
wiklou.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge "Allow users who are partially blocked to delete revisions."
[lhc/web/wiklou.git]
/
includes
/
widget
/
NamespaceInputWidget.php
diff --git
a/includes/widget/NamespaceInputWidget.php
b/includes/widget/NamespaceInputWidget.php
index
0840886
..
a360fb8
100644
(file)
--- a/
includes/widget/NamespaceInputWidget.php
+++ b/
includes/widget/NamespaceInputWidget.php
@@
-9,8
+9,10
@@
namespace MediaWiki\Widget;
* @license MIT
*/
class NamespaceInputWidget extends \OOUI\DropdownInputWidget {
* @license MIT
*/
class NamespaceInputWidget extends \OOUI\DropdownInputWidget {
-
- protected $includeAllValue = null;
+ /** @var string */
+ protected $includeAllValue;
+ /** @var int[] */
+ protected $exclude;
/**
* @param array $config Configuration options
/**
* @param array $config Configuration options
@@
-25,8
+27,8
@@
class NamespaceInputWidget extends \OOUI\DropdownInputWidget {
parent::__construct( $config );
// Properties
parent::__construct( $config );
// Properties
- $this->includeAllValue =
isset( $config['includeAllValue'] ) ? $config['includeAllValue'] :
null;
- $this->exclude =
isset( $config['exclude'] ) ? $config['exclude'] :
[];
+ $this->includeAllValue =
$config['includeAllValue'] ??
null;
+ $this->exclude =
$config['exclude'] ??
[];
// Initialization
$this->addClasses( [ 'mw-widget-namespaceInputWidget' ] );
// Initialization
$this->addClasses( [ 'mw-widget-namespaceInputWidget' ] );
@@
-34,8
+36,8
@@
class NamespaceInputWidget extends \OOUI\DropdownInputWidget {
protected function getNamespaceDropdownOptions( array $config ) {
$namespaceOptionsParams = [
protected function getNamespaceDropdownOptions( array $config ) {
$namespaceOptionsParams = [
- 'all' =>
isset( $config['includeAllValue'] ) ? $config['includeAllValue'] :
null,
- 'exclude' =>
isset( $config['exclude'] ) ? $config['exclude'] :
null
+ 'all' =>
$config['includeAllValue'] ??
null,
+ 'exclude' =>
$config['exclude'] ??
null
];
$namespaceOptions = \Html::namespaceSelectorOptions( $namespaceOptionsParams );
];
$namespaceOptions = \Html::namespaceSelectorOptions( $namespaceOptionsParams );