githubLogin method
Implementation
Future githubLogin() async {
UserCredential? github_login_result;
GithubAuthProvider githubProvider = GithubAuthProvider();
github_login_result =
await _read(authProvider).signInWithPopup(githubProvider);
final isFirstLogin = github_login_result.additionalUserInfo!.isNewUser;
if (isFirstLogin) {
if (kDebugMode) {
print('FirebasePlus : This is the first login');
}
return 0;
} else {
if (kDebugMode) {
print('FirebasePlus : This is the second and subsequent logins');
}
return 1;
}
}