mirror of
https://github.com/vitorpamplona/amethyst.git
synced 2025-11-10 22:06:43 +01:00
Throws an error if the RelayStats cannot be created.
This commit is contained in:
@@ -29,7 +29,7 @@ object RelayStats {
|
|||||||
override fun create(key: NormalizedRelayUrl): RelayStat = RelayStat()
|
override fun create(key: NormalizedRelayUrl): RelayStat = RelayStat()
|
||||||
}
|
}
|
||||||
|
|
||||||
fun get(url: NormalizedRelayUrl): RelayStat = innerCache.get(url) ?: RelayStat()
|
fun get(url: NormalizedRelayUrl): RelayStat = innerCache.get(url) ?: throw IllegalArgumentException("Should never happen")
|
||||||
|
|
||||||
fun addBytesReceived(
|
fun addBytesReceived(
|
||||||
url: NormalizedRelayUrl,
|
url: NormalizedRelayUrl,
|
||||||
|
|||||||
Reference in New Issue
Block a user