getUserInfo property
get current user info from :local value 'currentUser' @return user object @throws :Local not found on StorageException
Implementation
Future<User> get getUserInfo async {
try {
_node = await _storageController.get(":Local");
String userDetails = await _node!
.getValue("userDetails")
.then((value) => value!.getValue("en")!);
return User.convertUserFromJson(userDetails);
} on StorageException {
throw ("Node :Local not found");
}
}