diff --git a/src/main/java/cn/teammodel/service/impl/ChatMessageServiceImpl.java b/src/main/java/cn/teammodel/service/impl/ChatMessageServiceImpl.java index f1fff1e..f66bd4e 100644 --- a/src/main/java/cn/teammodel/service/impl/ChatMessageServiceImpl.java +++ b/src/main/java/cn/teammodel/service/impl/ChatMessageServiceImpl.java @@ -420,29 +420,21 @@ public class ChatMessageServiceImpl implements ChatMessageService { case 1:{ for (WisdomExamCommentsDto examComment : examComments) { builder.append(String.format(finalChatModel.getCycleChats().get(1), count, examComment.getName(),examComment.getTime(), examComment.getClassRate(),examComment.getGradeRate())); - if (count < examComments.size()) { - count++; - } + count++; } break; } case 2:{ for (WisdomExamCommentsDto examComment : examComments) { builder.append(String.format(finalChatModel.getCycleChats().get(2), count, examComment.getName(),examComment.getTime(), examComment.getGradeRate())); - if (count < examComments.size()) { - count++; - } + count++; } break; } default:{ for (WisdomExamCommentsDto examComment : examComments) { - builder.append(String.format(finalChatModel.getCycleChats().get(0), count, examComment.getName(), - examComment.getTime(), examComment.getScore(), examComment.getScoreRate(), - examComment.getRanking())); - if (count < examComments.size()) { - count++; - } + builder.append(String.format(finalChatModel.getCycleChats().get(0), count, examComment.getName(),examComment.getTime(), examComment.getScore(), examComment.getScoreRate(),examComment.getRanking())); + count++; } break; }