updateMetricPreferences static method

Future<void> updateMetricPreferences(
  1. Metric metric
)

Implementation

static Future<void> updateMetricPreferences(Metric metric) async {
  final pref = await SharedPreferences.getInstance();
  await pref.setDouble(kMetricsKey, metric.value);
}