getIn<T> method

  1. @override
Future<Result<List<T>>> getIn<T>({
  1. required List list,
  2. required dynamic fieldName,
})
override

Implementation

@override
Future<Result<List<T>>> getIn<T>(
    {required List<dynamic> list, required dynamic fieldName}) async {
  try {
    assert(ListUtils.instance.isNotEmpty(list));
    assert(fieldName != null);

    QuerySnapshot snapshot =
    await _collectionPath!.where(fieldName, whereIn: list).get();

    return _toList<T>(snapshot);
  } catch (e, stacktrace) {
    return _getErrorLog(
      msg: e.toString(),
      stacktrace: stacktrace,
    );
  }
}