package com.seven.ikar.kotlin.core.push

import java.util.concurrent.atomic.AtomicReference

object AndroidActiveChatState {
    private val activeChatId = AtomicReference<String?>(null)

    fun setActiveChatId(chatId: String?) {
        activeChatId.set(chatId?.takeIf { it.isNotBlank() })
    }

    fun getActiveChatId(): String? = activeChatId.get()
}
