pikapika/lib/basic/config/IsPro.dart

20 lines
457 B
Dart
Raw Normal View History

2022-07-09 07:11:26 +00:00
import 'package:event/event.dart';
import 'package:pikapika/basic/Method.dart';
import '../Entities.dart';
bool get isPro {
return _proInfoAll.proInfoAf.isPro || _proInfoAll.proInfoPat.isPro;
}
ProInfoAf get proInfoAf => _proInfoAll.proInfoAf;
ProInfoPat get proInfoPat => _proInfoAll.proInfoPat;
2022-07-09 07:11:26 +00:00
final proEvent = Event();
late ProInfoAll _proInfoAll;
2022-07-09 07:11:26 +00:00
Future reloadIsPro() async {
_proInfoAll = await method.proInfoAll();
2022-07-09 07:11:26 +00:00
proEvent.broadcast();
}