logout method
Logs out the current user from the cloud service.
Implementation
@override
Future<bool> logout() async {
if (_isAuthenticated) {
try {
await signOut();
_isAuthenticated = false; // This is redundant due to signOut but safe.
return true;
} catch (e) {
return false;
}
}
return false; // Already logged out.
}