Simplify boolean logic for Special:Block widgets
authorThalia <thalia.e.chan@googlemail.com>
Mon, 14 Jan 2019 20:51:20 +0000 (20:51 +0000)
committerThalia <thalia.e.chan@googlemail.com>
Wed, 16 Jan 2019 15:37:43 +0000 (15:37 +0000)
commitc39fff423ebe00df54d6ef024edc78220a9815af
tree0ffdc1cd0133ef77a3dfb79362ac04a46ce27ac8
parent918d9d8371be3936ecf83d335b1a92a0d9181b9f
Simplify boolean logic for Special:Block widgets

The boolean logic controlling the showing/hiding of widgets on
Special:Block could be expressed more simply. The logic is
becoming more complex due to partial blocks, so now is a good
time to rephrase it.

This removes safeguards against passing undefined to toggle,
so make sure none of the checks ever return undefined.

Change-Id: I1e0eb288db708be951fe5cf11f658725a38a7c4d
resources/src/mediawiki.special.block.js