Use Set instead of List

This commit is contained in:
Benoit Marty 2020-07-03 15:36:04 +02:00
parent 5f60d7fd3b
commit 6569ee5d10
1 changed files with 1 additions and 1 deletions

View File

@ -22,7 +22,7 @@ import javax.inject.Inject
internal class SessionListeners @Inject constructor() { internal class SessionListeners @Inject constructor() {
private val listeners = ArrayList<Session.Listener>() private val listeners = mutableSetOf<Session.Listener>()
fun addListener(listener: Session.Listener) { fun addListener(listener: Session.Listener) {
synchronized(listeners) { synchronized(listeners) {