asDouble function

double asDouble(
  1. Map<String, dynamic>? json,
  2. String key, {
  3. double defaultValue = 0.0,
})

Implementation

double asDouble(Map<String, dynamic>? json, String key,
    {double defaultValue = 0.0}) {
  if (json == null || !json.containsKey(key)) return defaultValue;
  return toDouble(json[key]);
}