in app/helpers/UserInfoCache.scala [117:138]
def addToMap(entry:(String, UserInfoBuilder), remaining:Seq[(String, UserInfoBuilder)], existingEntries:Map[String, Seq[UserInfoBuilder]]): Map[String, Seq[UserInfoBuilder]] = {
val updated = entry._2.vault match {
case Some(newVaultId)=>
existingEntries.get (newVaultId) match {
case Some (existingValues) =>
val newValues = existingValues :+ entry._2
existingEntries + (newVaultId -> newValues)
case None =>
val newValues = Seq (entry._2)
existingEntries + (newVaultId-> newValues)
}
case None=>
logger.warn(s"Vault informaiton ${entry._2} does not have a vault id??")
existingEntries
}
if(remaining.isEmpty) {
updated
} else {
addToMap(remaining.head, remaining.tail, updated)
}
}