From 8a0672a4a6453f9cd0cdf25a07623dfca9614591 Mon Sep 17 00:00:00 2001 From: To-om Date: Fri, 23 Jul 2021 15:25:53 +0200 Subject: [PATCH] #2135 Fix type to access cached flow items --- thehive/app/org/thp/thehive/services/FlowActor.scala | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/thehive/app/org/thp/thehive/services/FlowActor.scala b/thehive/app/org/thp/thehive/services/FlowActor.scala index bd715117d7..9fbd9883dc 100644 --- a/thehive/app/org/thp/thehive/services/FlowActor.scala +++ b/thehive/app/org/thp/thehive/services/FlowActor.scala @@ -109,12 +109,12 @@ class FlowActor extends Actor { case (id, organisations, cases) => organisations.foreach { organisation => val cacheKey = FlowId.toString(organisation, None) - val ids = cache.get[List[String]](cacheKey).getOrElse(Nil) - cache.set(cacheKey, (id :: ids).take(10)) + val ids = cache.get[Seq[String]](cacheKey).getOrElse(Nil) + cache.set(cacheKey, (id +: ids).take(10)) cases.foreach { caseId => val cacheKey: String = FlowId.toString(organisation, Some(caseId)) - val ids = cache.get[List[String]](cacheKey).getOrElse(Nil) - cache.set(cacheKey, (id :: ids).take(10)) + val ids = cache.get[Seq[String]](cacheKey).getOrElse(Nil) + cache.set(cacheKey, (id +: ids).take(10)) } } }