diff options
author | Vitaly Takmazov | 2022-12-24 03:15:44 +0300 |
---|---|---|
committer | Vitaly Takmazov | 2022-12-24 03:15:44 +0300 |
commit | 2a858017b7d9a620d1083b69b7ca038c34a5ba89 (patch) | |
tree | 3b192b9ab0aee2a38bbd3243a2977409ae6a033e /src/main/java/com/juick/www/api/Notifications.java | |
parent | 54f27794e7fee1113115baafe1b86fdbcde8e7c2 (diff) |
`Collectors.toList()` -> `toList()`
Diffstat (limited to 'src/main/java/com/juick/www/api/Notifications.java')
-rw-r--r-- | src/main/java/com/juick/www/api/Notifications.java | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/main/java/com/juick/www/api/Notifications.java b/src/main/java/com/juick/www/api/Notifications.java index 5f941ba5..09dad9e2 100644 --- a/src/main/java/com/juick/www/api/Notifications.java +++ b/src/main/java/com/juick/www/api/Notifications.java @@ -76,11 +76,11 @@ public class Notifications { pushQueriesService.getMPNSURL(uid).forEach(t -> user.getTokens().add(new ExternalToken(null, "mpns", t, null))); List<ExternalToken> xmppJids = userService.getJIDsbyUID(uid).stream() .map(jid -> new ExternalToken(null, "xmpp", jid, null)) - .collect(Collectors.toList()); + .toList(); user.getTokens().addAll(xmppJids); List<ExternalToken> tgIds = telegramService.getTelegramIdentifiers(Collections.singletonList(user)).stream() .map(tgId -> new ExternalToken(null, "durov", String.valueOf(tgId), null)) - .collect(Collectors.toList()); + .toList(); user.getTokens().addAll(tgIds); return user; } @@ -116,7 +116,7 @@ public class Notifications { } return users.stream().map(User::getUid) - .map(this::collectTokens).collect(Collectors.toList()); + .map(this::collectTokens).toList(); } else { // read return Collections.singletonList(collectTokens(uid)); |