From b6cb156530b5012f589d097fbbe84b855391accc Mon Sep 17 00:00:00 2001 From: Zipeng WU Date: Thu, 12 Jan 2023 15:07:29 +0100 Subject: [NO-JIRA] explicitly declare toList collector mutable or not --- .../sonar-ce-common/src/main/java/org/sonar/ce/queue/CeQueueImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'server/sonar-ce-common') diff --git a/server/sonar-ce-common/src/main/java/org/sonar/ce/queue/CeQueueImpl.java b/server/sonar-ce-common/src/main/java/org/sonar/ce/queue/CeQueueImpl.java index fe7fdd6179a..b124b509c02 100644 --- a/server/sonar-ce-common/src/main/java/org/sonar/ce/queue/CeQueueImpl.java +++ b/server/sonar-ce-common/src/main/java/org/sonar/ce/queue/CeQueueImpl.java @@ -138,7 +138,7 @@ public class CeQueueImpl implements CeQueue { List taskDtos = submissions.stream() .filter(filterBySubmitOptions(options, submissions, dbSession)) .map(submission -> addToQueueInDb(dbSession, submission)) - .collect(Collectors.toList()); + .toList(); List tasks = loadTasks(dbSession, taskDtos); dbSession.commit(); return tasks; -- cgit v1.2.3