fix demo code

This commit is contained in:
haranicle 2017-10-04 22:12:02 +09:00
parent 0768a23570
commit 555a19bcc9
1 changed files with 7 additions and 6 deletions

View File

@ -73,14 +73,15 @@ class DemoListViewController: UITableViewController, NohanaImagePickerController
switch PHPhotoLibrary.authorizationStatus() {
case .notDetermined:
PHPhotoLibrary.requestAuthorization { status in
switch status {
case .authorized:
handler(true)
default:
handler(false)
DispatchQueue.main.async {
switch status {
case .authorized:
handler(true)
default:
handler(false)
}
}
}
case .restricted:
handler(false)
case .denied: