import 'package:byod/models/member_info.dart';
import 'package:flutter_bloc/flutter_bloc.dart';

import '../api/api.dart';

class MemberInfoBloc extends Cubit<MemberInfo> {
  MemberInfoBloc()
      : super(MemberInfo(
            id: '',
            name: '',
            cardNumber: '',
            expireDate: '',
            promotionCode: '',
            tier: '',
            balance: ''));

  void getMemberInfo(String token) async {
    var memberInfo = await Api.memberInfo(token);
    emit(memberInfo);
  }
}
