@@ -9,31 +9,31 @@ import type Mithril from 'mithril';
9
9
export interface TwoFactorEnableModalAttrs extends IInternalModalAttrs {
10
10
user : User ;
11
11
forced : boolean ;
12
- onEnabled : ( ) => void | null ;
12
+ onEnabled : ( ) => void | null ;
13
13
}
14
14
15
15
export default class TwoFactorEnableModal extends Modal < TwoFactorEnableModalAttrs > {
16
16
user ! : User ;
17
17
// Statuses: 'loading', 'displayQR', 'displayBackupCodes', 'final'
18
18
status : string = 'loading' ;
19
- qrCodeUrl : string | null = null ;
19
+ qrCodeUrl : string | null = null ;
20
20
backupCodes : Array < string > = [ ] ;
21
21
token : Stream < string > ;
22
- code : string | null = null ;
22
+ code : string | null = null ;
23
23
activeTab : string = 'qrcode' ;
24
24
loading : boolean = false ;
25
25
26
26
protected static isDismissibleViaCloseButton : boolean = true ;
27
27
protected static isDismissibleViaEscKey : boolean = true ;
28
28
protected static isDismissibleViaBackdropClick : boolean = true ;
29
-
29
+
30
30
oninit ( vnode : Mithril . Vnode < TwoFactorEnableModalAttrs > ) {
31
31
super . oninit ( vnode ) ;
32
32
33
33
this . user = this . attrs . user ;
34
-
34
+
35
35
this . token = Stream ( '' ) ;
36
-
36
+
37
37
if ( this . attrs . forced ) {
38
38
TwoFactorEnableModal . isDismissibleViaCloseButton = false ;
39
39
TwoFactorEnableModal . isDismissibleViaEscKey = false ;
@@ -211,7 +211,7 @@ export default class TwoFactorEnableModal extends Modal<TwoFactorEnableModalAttr
211
211
}
212
212
213
213
finish ( ) {
214
- this . attrs . onEnabled ?.( )
214
+ this . attrs . onEnabled ?.( ) ;
215
215
this . hide ( ) ;
216
216
}
217
217
0 commit comments