diff --git a/Offroad-iOS/Offroad-iOS/Global/Extensions/UIView+.swift b/Offroad-iOS/Offroad-iOS/Global/Extensions/UIView+.swift index 7d0cdf9e..f2107d84 100644 --- a/Offroad-iOS/Offroad-iOS/Global/Extensions/UIView+.swift +++ b/Offroad-iOS/Offroad-iOS/Global/Extensions/UIView+.swift @@ -70,13 +70,12 @@ extension UIView { func startLoading(withoutShading: Bool = false) { - // 이미 로딩중인 경우, 추가 로딩 뷰 띄우는 것 방지 - for subView in subviews { - if subView is LoadingView { return } - } - DispatchQueue.main.async { [weak self] in guard let self else { return } + // 이미 로딩중인 경우, 추가 로딩 뷰 띄우는 것 방지 + for subView in subviews { + if subView is LoadingView { return } + } let loadingView = LoadingView() loadingView.shadeView.isHidden = withoutShading loadingView.isHidden = true diff --git a/Offroad-iOS/Offroad-iOS/Presentation/Chat/ChatLog/ViewControllers/CharacterChatLogViewController.swift b/Offroad-iOS/Offroad-iOS/Presentation/Chat/ChatLog/ViewControllers/CharacterChatLogViewController.swift index d0296332..ac6ee33f 100644 --- a/Offroad-iOS/Offroad-iOS/Presentation/Chat/ChatLog/ViewControllers/CharacterChatLogViewController.swift +++ b/Offroad-iOS/Offroad-iOS/Presentation/Chat/ChatLog/ViewControllers/CharacterChatLogViewController.swift @@ -152,7 +152,10 @@ extension CharacterChatLogViewController { } private func requestChatLogDataSource() { - tabBarController?.view.startLoading() + DispatchQueue.main.async { [weak self] in + guard let self else { return } + self.tabBarController?.view.startLoading() + } NetworkService.shared.characterChatService.getChatLog(completion: { [weak self] result in guard let self else { return } self.tabBarController?.view.stopLoading()