From 5327d1350261a280b1e0e3ad899439947dd3a186 Mon Sep 17 00:00:00 2001 From: anhefti Date: Wed, 16 Jun 2021 17:30:23 +0200 Subject: [PATCH] todo --- .../session/impl/SEBClientNotificationServiceImpl.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/main/java/ch/ethz/seb/sebserver/webservice/servicelayer/session/impl/SEBClientNotificationServiceImpl.java b/src/main/java/ch/ethz/seb/sebserver/webservice/servicelayer/session/impl/SEBClientNotificationServiceImpl.java index 93059772..4867e522 100644 --- a/src/main/java/ch/ethz/seb/sebserver/webservice/servicelayer/session/impl/SEBClientNotificationServiceImpl.java +++ b/src/main/java/ch/ethz/seb/sebserver/webservice/servicelayer/session/impl/SEBClientNotificationServiceImpl.java @@ -52,10 +52,14 @@ public class SEBClientNotificationServiceImpl implements SEBClientNotificationSe this.sebClientInstructionService = sebClientInstructionService; } + // TODO find a better (faster) way to update pending notifications + // get them all at certain interval with background update for example + // or update them all on every monitoring call + @Override public Boolean hasAnyPendingNotification(final Long clientConnectionId) { - if (this.pendingNotifications.add(clientConnectionId)) { + if (this.pendingNotifications.contains(clientConnectionId)) { return true; }