removed redundant ToList() calls and added line break after region
This commit is contained in:
@@ -138,6 +138,7 @@ namespace MongoDbGenericRepository
|
|||||||
}
|
}
|
||||||
|
|
||||||
#region Find And Update
|
#region Find And Update
|
||||||
|
|
||||||
/// <inheritdoc />
|
/// <inheritdoc />
|
||||||
public virtual async Task<TDocument> GetAndUpdateOne<TDocument>(
|
public virtual async Task<TDocument> GetAndUpdateOne<TDocument>(
|
||||||
FilterDefinition<TDocument> filter,
|
FilterDefinition<TDocument> filter,
|
||||||
|
|||||||
@@ -69,7 +69,7 @@ namespace MongoDbGenericRepository.DataAccess.Create
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
await GetCollection<TDocument, TKey>().InsertManyAsync(documentsList.ToList(), null, cancellationToken);
|
await GetCollection<TDocument, TKey>().InsertManyAsync(documentsList, null, cancellationToken);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -100,7 +100,7 @@ namespace MongoDbGenericRepository.DataAccess.Create
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
GetCollection<TDocument, TKey>().InsertMany(documentList.ToList(), cancellationToken: cancellationToken);
|
GetCollection<TDocument, TKey>().InsertMany(documentList, cancellationToken: cancellationToken);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user