Commit b9129576 authored by Him188's avatar Him188

effective function name

parent 98540004
......@@ -18,7 +18,7 @@ private const val IMAGE_BUFFER_CAPACITY: Int = 5
@ExperimentalUnsignedTypes
@ExperimentalCoroutinesApi
object Gentlemen : MutableMap<UInt, Gentleman> by mutableMapOf() {
fun getOrPut(key: Contact): Gentleman = this.getOrPut(key.id) { Gentleman(key) }
fun provide(key: Contact): Gentleman = this.getOrPut(key.id) { Gentleman(key) }
}
/**
......
......@@ -43,7 +43,7 @@ suspend fun main() {
try {
repeat(it.toIntOrNull() ?: 1) {
launch {
Gentlemen.getOrPut(subject).receive().image.await().send()
Gentlemen.provide(subject).receive().image.await().send()
}
}
} catch (e: Exception) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment