Skip to content

Commit

Permalink
Making sure the presenting of the controller always happens in the ma…
Browse files Browse the repository at this point in the history
…in thread
  • Loading branch information
Erik Sargent committed May 10, 2016
1 parent 9be2316 commit 49bc1a9
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion LKAlertController.podspec
Expand Up @@ -9,7 +9,7 @@

Pod::Spec.new do |s|
s.name = "LKAlertController"
s.version = "1.9.0"
s.version = "1.9.1"
s.summary = "An easy to use UIAlertController builder for swift"
s.homepage = "https://github.com/lightningkite/LKAlertController"
s.license = 'MIT'
Expand Down
6 changes: 4 additions & 2 deletions Pod/Classes/LKAlertController.swift
Expand Up @@ -177,8 +177,10 @@ public class LKAlertController {
if let source = presentationSource {
presentedController = source
}

presentedController.presentViewController(alertController, animated: animated, completion: completion)

dispatch_async(dispatch_get_main_queue()) {
presentedController.presentViewController(self.alertController, animated: animated, completion: completion)
}
}
}

Expand Down

0 comments on commit 49bc1a9

Please sign in to comment.