checkUnread method

Future<Either<BaseException, bool>> checkUnread()

Implementation

Future<Either<BaseException, bool>> checkUnread() {
  return get(
    NotificationsUrls.countUnread,
    mapper: (json) {
      final countUnread = json['unreadCount'] ?? 0;

      if (countUnread > 0) return true;

      return false;
    },
  );
}