Skip to content

Commit 2f1771e

Browse files
committed
Avoid obsolete inspection of DefaultedPageable.
The instance can never be null and thus we don't actually have to check for that.
1 parent cd3f9cb commit 2f1771e

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

spring-data-rest-webmvc/src/main/java/org/springframework/data/rest/webmvc/RepositoryEntityController.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -194,10 +194,7 @@ public CollectionModel<?> getCollectionResource(@QuerydslPredicate RootResourceI
194194
throw new ResourceNotFoundException();
195195
}
196196

197-
Iterable<?> results = pageable.getPageable() != null //
198-
? invoker.invokeFindAll(pageable.getPageable()) //
199-
: invoker.invokeFindAll(sort);
200-
197+
Iterable<?> results = invoker.invokeFindAll(pageable.getPageable());
201198
ResourceMetadata metadata = resourceInformation.getResourceMetadata();
202199
Optional<Link> baseLink = Optional.of(getDefaultSelfLink());
203200

0 commit comments

Comments
 (0)