diff --git a/lib/ui/home_page.dart b/lib/ui/home_page.dart index 900f047a033814372605ffc4d63208eaedaac6ef..6664c0fb7e0f6f3d2ad692f1bb21deac2ba936ec 100644 --- a/lib/ui/home_page.dart +++ b/lib/ui/home_page.dart @@ -54,6 +54,7 @@ class _HomePageState extends State { @override void initState() { + super.initState(); _textController.addListener(_applyFilteringAndRefresh); _loadCodes(); _streamSubscription = Bus.instance.on().listen((event) { @@ -64,7 +65,7 @@ class _HomePageState extends State { await autoLogoutAlert(context); }); _initDeepLinks(); - super.initState(); + } void _loadCodes() { @@ -222,7 +223,11 @@ class _HomePageState extends State { } else { final list = ListView.builder( itemBuilder: ((context, index) { - return CodeWidget(_filteredCodes[index]); + try { + return CodeWidget(_filteredCodes[index]); + } catch(e) { + return const Text("Failed"); + } }), itemCount: _filteredCodes.length, );