DATAMONGO-2570 - Change type of count variable to primitive.

Avoiding unintentional unboxing.

Original pull request: #871.
This commit is contained in:
Mehran Behnam
2020-06-18 13:00:06 +04:30
committed by Mark Paluch
parent 33624fcc6a
commit b0814d334f

View File

@@ -47,6 +47,7 @@ import org.springframework.util.Assert;
* @author Christoph Strobl
* @author Thomas Darimont
* @author Mark Paluch
* @author Mehran Behnam
*/
public class SimpleMongoRepository<T, ID> implements MongoRepository<T, ID> {
@@ -214,7 +215,7 @@ public class SimpleMongoRepository<T, ID> implements MongoRepository<T, ID> {
Assert.notNull(pageable, "Pageable must not be null!");
Long count = count();
long count = count();
List<T> list = findAll(new Query().with(pageable));
return new PageImpl<T>(list, pageable, count);