copyWith method

PhoneNumberAuthenticationSettings copyWith({
  1. bool? allowFlashCall,
  2. bool? allowMissedCall,
  3. bool? isCurrentPhoneNumber,
  4. bool? allowSmsRetrieverApi,
  5. FirebaseAuthenticationSettings? firebaseAuthenticationSettings()?,
  6. List<String>? authenticationTokens,
})

Returns a copy with the given fields replaced. For a nullable field pass a function, e.g. field: () => null to clear it.

Implementation

PhoneNumberAuthenticationSettings copyWith({
  bool? allowFlashCall,
  bool? allowMissedCall,
  bool? isCurrentPhoneNumber,
  bool? allowSmsRetrieverApi,
  FirebaseAuthenticationSettings? Function()? firebaseAuthenticationSettings,
  List<String>? authenticationTokens,
}) =>
    PhoneNumberAuthenticationSettings(
      allowFlashCall: allowFlashCall ?? this.allowFlashCall,
      allowMissedCall: allowMissedCall ?? this.allowMissedCall,
      isCurrentPhoneNumber: isCurrentPhoneNumber ?? this.isCurrentPhoneNumber,
      allowSmsRetrieverApi: allowSmsRetrieverApi ?? this.allowSmsRetrieverApi,
      firebaseAuthenticationSettings: firebaseAuthenticationSettings != null
          ? firebaseAuthenticationSettings()
          : this.firebaseAuthenticationSettings,
      authenticationTokens: authenticationTokens ?? this.authenticationTokens,
    );