From e22e55772abe7e91164e955f2e002e3670382cfa Mon Sep 17 00:00:00 2001 From: yangpengming Date: Fri, 1 Sep 2023 16:13:53 +0800 Subject: [PATCH] =?UTF-8?q?long=20=E8=BD=ACint=20=E8=B6=85=E5=87=BAint?= =?UTF-8?q?=E8=8C=83=E5=9B=B4=E5=BC=82=E5=B8=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/java3y/austin/web/service/impl/DataServiceImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/austin-web/src/main/java/com/java3y/austin/web/service/impl/DataServiceImpl.java b/austin-web/src/main/java/com/java3y/austin/web/service/impl/DataServiceImpl.java index 5925795..0e0a9f6 100644 --- a/austin-web/src/main/java/com/java3y/austin/web/service/impl/DataServiceImpl.java +++ b/austin-web/src/main/java/com/java3y/austin/web/service/impl/DataServiceImpl.java @@ -71,7 +71,7 @@ public class DataServiceImpl implements DataService { } // 0. 按时间排序 - List sortAnchorList = userInfoList.stream().map(s -> JSON.parseObject(s, SimpleAnchorInfo.class)).sorted((o1, o2) -> Math.toIntExact(o1.getTimestamp() - o2.getTimestamp())).collect(Collectors.toList()); + List sortAnchorList = userInfoList.stream().map(s -> JSON.parseObject(s, SimpleAnchorInfo.class)).sorted(Comparator.comparing(SimpleAnchorInfo::getTimestamp).reversed()).collect(Collectors.toList()); return buildUserTimeLineVo(sortAnchorList); }