-
Type: Bug
-
Resolution: Done
-
Priority: Trivial - P5
-
Affects Version/s: None
-
Component/s: Operations
-
None
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.
Unable to find source-code formatter for language: csharp. Available languages are: actionscript, ada, applescript, bash, c, c#, c++, cpp, css, erlang, go, groovy, haskell, html, java, javascript, js, json, lua, none, nyan, objc, perl, php, python, r, rainbow, ruby, scala, sh, sql, swift, visualbasic, xml, yaml
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));