scopesContextListFromJson function

List<ScopesContext> scopesContextListFromJson(
  1. List? scopesContext, [
  2. List<ScopesContext>? defaultValue
])

Implementation

List<enums.ScopesContext> scopesContextListFromJson(
  List? scopesContext, [
  List<enums.ScopesContext>? defaultValue,
]) {
  if (scopesContext == null) {
    return defaultValue ?? [];
  }

  return scopesContext.map((e) => scopesContextFromJson(e.toString())).toList();
}