Details
-
Bug
-
Resolution: Done
-
Trivial - P5
-
None
-
None
Description
FindOneAndUpdate and FindOneAndUpdateAsync methods have duplicated checks for collection not being null, but no checks for filter as other methods do.
Possible it is a typo and one check is excessive, or it is a bug and some necessary check is not done.
public static TDocument FindOneAndUpdate<TDocument>(this IMongoCollection<TDocument> collection, FilterDefinition<TDocument> filter, UpdateDefinition<TDocument> update, FindOneAndUpdateOptions<TDocument, TDocument> options = null, CancellationToken cancellationToken = default(CancellationToken)) |
{
|
Ensure.IsNotNull(collection, nameof(collection));
|
Ensure.IsNotNull(collection, nameof(collection));
|