Reference from https://gist.github.com/steipete/5664345
Guard against accessing UIKit on threads other than main.
Reference from https://gist.github.com/steipete/5664345
Guard against accessing UIKit on threads other than main.
https://gist.github.com/steipete/5664345
MIT License