getUserPreferenceForFit method

Future<void> getUserPreferenceForFit()

Implementation

Future<void> getUserPreferenceForFit() async {
  prefs = await SharedPreferences.getInstance();
  String fitValue = (await prefs?.getString('fit')) ?? "fill";
  _videoFit.value = fits.firstWhere((element) => element.name == fitValue);
  print("Last fit used was ${_videoFit.value.name}");
}