complete method
Implementation
@override
void complete(covariant List<Object?> value) {
if (!_isClosed) {
// Cast the list to List<T>
// This handles the case where we receive a List<Object?> that needs to be List<T>
final typedList = List<T>.from(value);
completer.complete(typedList);
onClose();
}
}