Future<bool> hasNetwork() async { final result = await Connectivity().checkConnectivity(); return !result.contains(ConnectivityResult.none); }