Skip to content

Instantly share code, notes, and snippets.

@ijoschek ijoschek/.\lib\scr\home.dart Secret
Created Dec 4, 2018

Embed
What would you like to do?
flutter_auth_tut
class _Home extends State<StatefulWidget> {
//...
void clickLogout() {
setState(() {
isLoggingIn = true;
});
logoutWithGoogle().whenComplete(() => setState(() {
isLoggingIn = false;
mUserName = 'No user is logged in!';
}));
}
void clickDelete() {
setState(() {
isLoggingIn = true;
});
deleteUserWithGoogle(mUser).whenComplete(() => setState(() {
isLoggingIn = false;
mUser = null;
mUserName = 'No user is logged in!';
}));
}
@override
Widget build(BuildContext context) {
// ...
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.