tryReadList method

List? tryReadList(
  1. dynamic source,
  2. dynamic key
)

Tries to read a list value from the source. If the value is not a list, it returns null.

Implementation

List? tryReadList(source, key) {
  var value = readValue(source, key);
  return isList(value) ? value as List : null;
}