Skip to content

Commit

Permalink
Update getOrAwaitValue.kt
Browse files Browse the repository at this point in the history
  • Loading branch information
kimdohun0104 authored Jun 8, 2021
1 parent 232a33c commit 055ce04
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import kotlinx.coroutines.withTimeout
*/
internal suspend fun <T> LiveData<T>.getOrAwaitValue(): T? =
try {
withTimeout(500) {
withTimeout(200) {
this@getOrAwaitValue.asFlow().first()
}
} catch (e: TimeoutCancellationException) {
Expand Down

0 comments on commit 055ce04

Please sign in to comment.