getUserEmail method
Get user email.
Attention! User need to be logged in with accepted VKScope.email scope.
If not logged in, decline VKScope.email scope than returns null
.
Implementation
Future<String?> getUserEmail() async {
final token = await accessToken;
if (!_isLoggedIn(token)) {
if (debug) _log('Not logged in. Email is null');
return null;
}
return token!.email;
}