findFirst method

T findFirst ()

Finds Objects matching the query and returns the first result or null if there are no results.

Implementation

T findFirst() {
  offset(0);
  limit(1);
  final list = find();
  return (list.isEmpty ? null : list[0]);
}