Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
Total | |
0.00% |
0 / 9 |
|
0.00% |
0 / 1 |
CRAP | |
0.00% |
0 / 1 |
Hooks | |
0.00% |
0 / 9 |
|
0.00% |
0 / 1 |
6 | |
0.00% |
0 / 1 |
onAuthChangeFormFields | |
0.00% |
0 / 9 |
|
0.00% |
0 / 1 |
6 |
1 | <?php |
2 | |
3 | namespace MediaWiki\Extension\EmailAuth; |
4 | |
5 | use MediaWiki\Auth\AuthenticationRequest; |
6 | |
7 | class Hooks { |
8 | public static function onAuthChangeFormFields( |
9 | array $requests, array $fieldInfo, array &$formDescriptor, $action |
10 | ) { |
11 | if ( AuthenticationRequest::getRequestByClass( $requests, |
12 | EmailAuthAuthenticationRequest::class ) |
13 | ) { |
14 | $formDescriptor['token'] += [ |
15 | 'size' => 6, |
16 | 'autofocus' => true, |
17 | 'persistent' => false, |
18 | 'autocomplete' => false, |
19 | 'spellcheck' => false, |
20 | ]; |
21 | } |
22 | } |
23 | } |