Skip to content
This repository has been archived by the owner on Jul 1, 2022. It is now read-only.

Allow CameraViewController to be used in a navigation stack without losing completion #271

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -541,7 +541,6 @@ open class CameraViewController: UIViewController {

internal func close() {
onCompletion?(nil, nil)
onCompletion = nil
}

internal func showLibrary() {
Expand Down Expand Up @@ -605,7 +604,6 @@ open class CameraViewController: UIViewController {
}

self?.onCompletion?(image, asset)
self?.onCompletion = nil
}
confirmViewController.modalTransitionStyle = UIModalTransitionStyle.crossDissolve
present(confirmViewController, animated: true, completion: nil)
Expand All @@ -623,7 +621,6 @@ open class CameraViewController: UIViewController {
}

self?.onCompletion?(image, asset)
self?.onCompletion = nil
}
confirmViewController.modalTransitionStyle = UIModalTransitionStyle.crossDissolve
present(confirmViewController, animated: true, completion: nil)
Expand Down