Xml::inputLabel does not know about boolean parameters like autofocus,
so add it with an empty value or omitted it.
Fix validation error:
Bad value 1 for attribute autofocus on element input.
Change-Id: Idb7a7b58079d6c44b5a7f1fa226218bb685c8241
[
'class' => 'mw-ui-input-inline mw-autocomplete-user',
'tabindex' => 1,
- 'autofocus' => $this->requestedUser === '',
- ]
+ ] + (
+ // Set autofocus on blank input
+ $this->requestedUser === '' ? [ 'autofocus' => '' ] : []
+ )
) . '<br />';
$out .= Xml::checkLabel( $this->msg( 'activeusers-hidebots' )->text(),