deleteCredential method
Deletes a credential that is no longer valid for signing into the app. More about this https://developers.google.com/android/reference/com/google/android/gms/auth/api/credentials/CredentialsApi?hl=en#save(com.google.android.gms.common.api.GoogleApiClient,%20com.google.android.gms.auth.api.credentials.Credential)
Implementation
Future<bool> deleteCredential({
// Value you want to save
required String id,
// Identifier url, should be you App's website url
String? accountType,
String? name,
String? password,
String? profilePictureUri,
}) async {
if (_isAndroid(Methods.deleteCredential)) {
try {
final res = await _channel.invokeMethod(Methods.deleteCredential, {
'id': id,
'accountType': accountType,
'name': name,
'password': password,
'profilePictureUri': profilePictureUri,
});
return res == true;
} catch (error) {
debugPrint('Pinput/SmartAuth: deleteCredential failed: $error');
return false;
}
}
return false;
}