import 'package:flutter/widgets.dart';
import 'package:flutter_bloc/flutter_bloc.dart';
import 'package:pharmacy_mobile/blocs/guest/guest_bloc.dart';
import 'package:pharmacy_mobile/blocs/guest/guest_event.dart';

Future<bool> blocGetGuestStatus(BuildContext context) async {
  try {
    final guestBloc = context.read<GuestBloc>();
    guestBloc.add(GuestGetStatus());
    return guestBloc.state.value;
  } catch (e) {
    return false;
  }
}
