getValueOr<T> method

T getValueOr<T>({
  1. required String name,
  2. required T defaultValue,
})

Implementation

T getValueOr<T>({
  required String name,
  required T defaultValue,
}) {
  if (this?.containsKey(name) == true && this?[name] != null) {
    return _getValueOr(this?[name], defaultValue);
  } else {
    return defaultValue;
  }
}