Skip to content

Commit

Permalink
fix/#388 코드리뷰 반영
Browse files Browse the repository at this point in the history
  • Loading branch information
youz2me committed Sep 20, 2024
1 parent f52f7ad commit 8b87375
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ private extension ChooseContentViewController {

viewModel.isSuccess.bindOnMain(with: self) { owner, success in
if success {
let viewController = AddPromiseCompleteViewController(promiseID: self.viewModel.promiseID)
let viewController = AddPromiseCompleteViewController(promiseID: owner.viewModel.promiseID)

viewController.setupNavigationBarTitle(with: "약속 수정하기")
viewController.rootView.titleLabel.text = "약속이 수정되었어요!"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ private extension PromiseViewController {
}

viewModel.isFinishSuccess.bindOnMain(with: self) { owner, isSuccess in
guard let isSuccess = isSuccess else { return }
guard let isSuccess else { return }

if isSuccess {
self.navigationController?.popViewController(animated: true)
Expand All @@ -179,8 +179,8 @@ private extension PromiseViewController {
}

viewModel.errorMessage.bindOnMain(with: self) { owner, message in
guard let message else { return }
let toast = Toast()
guard let message = message else { return }

toast.show(message: message, view: owner.view, position: .bottom, inset: 100)
}
Expand Down Expand Up @@ -237,8 +237,7 @@ extension PromiseViewController: CustomActionSheetDelegate {
viewModel.deletePromise()

dismiss(animated: false)
}
else {
} else {
viewModel.exitPromise()

dismiss(animated: false)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ private extension TardyViewController {
$0.tardyEmptyView.isHidden = true
$0.noTardyView.isHidden = true

owner.rootView.tardyCollectionView.reloadData()
$0.tardyCollectionView.reloadData()
}
case .noTardyView:
owner.rootView.do {
Expand Down Expand Up @@ -115,7 +115,7 @@ private extension TardyViewController {
$0.tardyEmptyView.isHidden = true
$0.noTardyView.isHidden = true

owner.rootView.tardyCollectionView.reloadData()
$0.tardyCollectionView.reloadData()
}
case .noTardyView:
owner.rootView.do {
Expand Down Expand Up @@ -157,7 +157,10 @@ extension TardyViewController: UICollectionViewDataSource {
}

cell.nameLabel.setText(tardyName, style: .body06, color: .gray6)
cell.profileImageView.kf.setImage(with: URL(string: viewModel.tardyList.value[indexPath.row].profileImageURL ?? ""), placeholder: UIImage.imgProfile)
cell.profileImageView.kf.setImage(
with: URL(string: viewModel.tardyList.value[indexPath.row].profileImageURL ?? ""),
placeholder: UIImage.imgProfile
)

return cell
}
Expand Down

0 comments on commit 8b87375

Please sign in to comment.