Skip to content

Commit 45b866b

Browse files
committed
[BOOK-291] fix: initialLoad에서 CancellationException일 경우 throw
1 parent d8fcc92 commit 45b866b

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/book/BookDetailPresenter.kt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ import kotlinx.collections.immutable.ImmutableList
3838
import kotlinx.collections.immutable.persistentListOf
3939
import kotlinx.collections.immutable.toImmutableList
4040
import kotlinx.collections.immutable.toPersistentList
41+
import kotlinx.coroutines.CancellationException
4142
import kotlinx.coroutines.async
4243
import kotlinx.coroutines.coroutineScope
4344
import kotlinx.coroutines.launch
@@ -120,6 +121,8 @@ class BookDetailPresenter @AssistedInject constructor(
120121

121122
uiState = UiState.Success
122123
}
124+
} catch (ce: CancellationException) {
125+
throw ce
123126
} catch (e: Throwable) {
124127
uiState = UiState.Error(e)
125128

0 commit comments

Comments
 (0)