BAEL-20663: Fix usage of org.springframework.data.domain.Sort

This commit is contained in:
Krzysiek 2020-01-07 21:58:14 +01:00
parent fc22587009
commit 80741d0d31
1 changed files with 1 additions and 1 deletions

View File

@ -49,7 +49,7 @@ public class EmployeeServicesWithKeyValueTemplate implements EmployeeService {
@Override
public Iterable<Employee> getSortedListOfEmployeesBySalary() {
KeyValueQuery query = new KeyValueQuery();
query.setSort(new Sort(Sort.Direction.DESC, "salary"));
query.setSort(Sort.by(Sort.Direction.DESC, "salary"));
return keyValueTemplate.find(query, Employee.class);
}