Open TatuSaa opened 4 years ago
While pushing logout you are actually logged out from Firebase but it won't return to authentication screen.
Error: Exception caught by provider The following assertion was thrown: An exception was throw by _MapStream<FirebaseUser, User> listened by
StreamProvider, but no catchError was provided.
catchError
Exception: NoSuchMethodError: The getter 'uid' was called on null. Receiver: null Tried calling: uid
FIX: @override Widget build(BuildContext context) { return StreamProvider.value( catchError: (_, __) => null, //add above to main.dart value: AuthService().user, child: MaterialApp( home: Wrapper(),
While pushing logout you are actually logged out from Firebase but it won't return to authentication screen.
Error: Exception caught by provider The following assertion was thrown: An exception was throw by _MapStream<FirebaseUser, User> listened by
StreamProvider, but no
catchError
was provided.Exception: NoSuchMethodError: The getter 'uid' was called on null. Receiver: null Tried calling: uid
FIX: @override Widget build(BuildContext context) { return StreamProvider.value(
catchError: (_, __) => null,
//add above to main.dart
value: AuthService().user,
child: MaterialApp(
home: Wrapper(),