-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Hotfix] #430 - 솝탬프 디테일뷰 크래시 이슈 해결 #431
Conversation
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
솝탬프를 책임지는 재현이 . . 이번에 꼬옥 해결되면 좋겠어요..🫶🫶🫶
그리고 머지하는 브랜치 release
로 변경해주세요!!
@@ -154,19 +158,22 @@ extension ListDetailViewModel { | |||
|
|||
listDetailModel.asDriver() | |||
.compactMap { | |||
self.uploadedUrl = $0.image |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
release브랜치에 반영되었던 부분인데 혹시 release 브랜치에서 새 브랜치 파신게 맞는지 확인 한 번 더 부탁드립니다!_!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
그리고 이 부분에서도 self로 뷰모델을 참조하는데 다시 self의 cancelBag에 저장되기 때문에 순환참조가 발생할 것 같습니다 !
self.uploadedUrl = $0.image | |
listDetailModel.asDrivaer() | |
.withUnretained(self) | |
.compactMap { owner, model in | |
self.uploadedUrl = model.image | |
self.stampId = model.stampId | |
return model | |
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
release브랜치에 반영되었던 부분인데 혹시 release 브랜치에서 새 브랜치 파신게 맞는지 확인 한 번 더 부탁드립니다!_!
🥹 실수입니다 .. 잘 되돌려놓겠습니다..
@@ -174,50 +178,54 @@ extension ListDetailVC { | |||
|
|||
output.$listDetailModel | |||
.compactMap { $0 } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
withUnretained 내부에서 compactMap으로 nil을 필터링 해주고 있기 때문에 해당 코드는 지워주세요@!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
withUnretained
내부에 있는 compactMap은 self만 옵셔널 해제를 해주고 있고, model 자체가 옵셔널로 선언되어 있어서 이 친구에 대한 해제가 필요할 것 같다구 생각했습니다!.!
compactMap { [weak object] output in
guard let object = object else {
return nil
}
return (object, output)
}
@Published var listDetailModel: ListDetailModel?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
헉!! 제가 self만 확인하고 listDetailModel은 생각을 못했네요..!_! 정정 감사합니다🙌
@@ -75,6 +75,7 @@ extension ListDetailViewModel { | |||
.filter { owner, _ in | |||
owner.sceneType == .completed | |||
} | |||
.withUnretained(self) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
혹시 한 번 더 withUnretained를 해준 이유가 있을까요?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
약한 참조가 필요한 부분마다 .withUnretained(self)
를 해줘야 한다고 잘못 이해했었어요..! 지금 살펴보니까 중복해서 할 필요가 업네요.. 지우겠습니다 !!
8a4aff3
to
b4fa968
Compare
🌴 PR 요약
🌱 작업한 브랜치
🌱 PR Point
지속되고 있는 솝탬프 디테일뷰 크래시 이슈를 해결하고자 합니다.
EXC_BAD_ACCESS
가 발생하는 것을 확인했습니다.2.6.2
버전으로, 이슈의 원인으로 추정할 수 있는 여러 부분들을 수정해 재배포하려 합니다.수정한 부분
📌 참고 사항
생략
📸 스크린샷
생략
📮 관련 이슈