Skip to content

Commit 02882be

Browse files
committed
refactor: use Java 16 syntax for lists
1 parent b024f78 commit 02882be

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

docs/changelog.md

+1
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ category: Administration
1515
* feat: ensure compatibility with Jira 10.3.0
1616
* refactor: improve structure of subtask creation service
1717
* feat: ensure compatibility with Jira 10.4.0
18+
* refactor: use Java 16 syntax for lists
1819

1920
### [24.11.0] - 2024-11-11
2021

src/main/java/de/codescape/jira/plugins/multiplesubtasks/model/Subtask.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,7 @@ private Map<String, List<String>> extractCustomFieldsById(ArrayListMultimap<Stri
262262
// get all custom field keys
263263
List<String> customFieldKeys = attributes.keySet().stream()
264264
.filter(s -> CUSTOM_FIELD_ID_PATTERN.matcher(s).matches())
265-
.collect(Collectors.toList());
265+
.toList();
266266
// collect all keys and values into a map
267267
Map<String, List<String>> customFields = new HashMap<>();
268268
customFieldKeys.forEach(s -> customFields.put(s, new ArrayList<>(attributes.get(s))));
@@ -273,7 +273,7 @@ private Map<String, List<String>> extractCustomFieldsByName(ArrayListMultimap<St
273273
// get all custom field keys
274274
List<String> customFieldKeys = attributes.keySet().stream()
275275
.filter(s -> CUSTOM_FIELD_NAME_PATTERN.matcher(s).matches())
276-
.collect(Collectors.toList());
276+
.toList();
277277
// collect all keys and values into a map
278278
Map<String, List<String>> customFields = new HashMap<>();
279279
customFieldKeys.forEach(key -> customFields.put(extractCustomFieldName(key), new ArrayList<>(attributes.get(key))));

0 commit comments

Comments
 (0)