File tree Expand file tree Collapse file tree 1 file changed +5
-6
lines changed 
packages/firebase_ui_auth/lib/src/widgets Expand file tree Collapse file tree 1 file changed +5
-6
lines changed Original file line number Diff line number Diff line change @@ -85,8 +85,8 @@ class _DeleteAccountButtonState extends State<DeleteAccountButton> {
8585  void  Function () pop <T >(BuildContext  context, T  result) => 
8686      () =>  Navigator .of (context).pop (result);
8787
88-   Future <void > _deleteAccount () async  {
89-     bool ?  confirmed =  ! widget.showDeleteConfirmationDialog;
88+   Future <void > _deleteAccount ({ bool  skipConfirmation  =   false } ) async  {
89+     bool ?  confirmed =  skipConfirmation  ||   ! widget.showDeleteConfirmationDialog;
9090
9191    if  (! confirmed) {
9292      final  l =  FirebaseUILocalizations .labelsOf (context);
@@ -116,17 +116,16 @@ class _DeleteAccountButtonState extends State<DeleteAccountButton> {
116116      final  user =  auth.currentUser! ;
117117      await  auth.currentUser? .delete ();
118118
119-       FirebaseUIAction .ofType <AccountDeletedAction >(context) ? . callback ( 
119+       FirebaseUIAction .ofType <AccountDeletedAction >(
120120        context,
121-         user,
122-       );
121+       )? .callback (context, user);
123122      await  FirebaseUIAuth .signOut (context:  context, auth:  auth);
124123    } on  fba.FirebaseAuthException  catch  (err) {
125124      if  (err.code ==  'requires-recent-login' ) {
126125        if  (widget.onSignInRequired !=  null ) {
127126          final  signedIn =  await  widget.onSignInRequired !();
128127          if  (signedIn) {
129-             await  _deleteAccount ();
128+             await  _deleteAccount (skipConfirmation :   true );
130129          }
131130        }
132131      }
    
 
   
 
     
   
   
          
     
  
    
     
 
    
      
     
 
     
    You can’t perform that action at this time.
  
 
    
  
     
    
      
        
     
 
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments