make MyApp stateful so the linter fucking shuts up

This commit is contained in:
Lea 2023-02-05 20:54:11 +01:00
parent 7bc2d763df
commit d12c5d0349
Signed by: Lea
GPG key ID: 1BAFFE8347019C42

View file

@ -22,13 +22,18 @@ final api = FeverAPI();
void main() { void main() {
setupBackgroundTasks(); setupBackgroundTasks();
runApp(MyApp()); runApp(const MyApp());
} }
class MyApp extends StatelessWidget { class MyApp extends StatefulWidget {
SharedPreferences? prefs; const MyApp({super.key});
MyApp({super.key}); @override
State<MyApp> createState() => _MyAppState();
}
class _MyAppState extends State<MyApp> {
SharedPreferences? prefs;
Future<bool> _loadPrefs() async { Future<bool> _loadPrefs() async {
var prefs = await SharedPreferences.getInstance(); var prefs = await SharedPreferences.getInstance();