mirror of
https://github.com/Sheldan/abstracto.git
synced 2026-05-17 05:17:06 +00:00
[AB-xxx] filtering current section from past sections in twitch stream notifications to not duplicate the information in case of a refresh
This commit is contained in:
@@ -174,6 +174,7 @@ public class StreamerServiceBean implements StreamerService {
|
||||
.getCurrentSession()
|
||||
.getSections()
|
||||
.stream()
|
||||
.filter(pastSection -> !pastSection.getTitle().equals(stream.getTitle()) && !pastSection.getGameId().equals(stream.getGameId())) // filter out the current section in case it was refreshed
|
||||
.sorted(Comparator.comparing(StreamSessionSection::getId).reversed())
|
||||
.map(StreamSectionDisplay::fromSection)
|
||||
.toList();
|
||||
|
||||
Reference in New Issue
Block a user