Skip to content

Instantly share code, notes, and snippets.

@llinardos
Last active May 7, 2018 00:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save llinardos/ca88472c57cccc0d6d5e7028a0cac477 to your computer and use it in GitHub Desktop.
Save llinardos/ca88472c57cccc0d6d5e7028a0cac477 to your computer and use it in GitHub Desktop.
let syncService = SyncronicThingsService()
activityIndicator.startAnimating()
DispatchQueue.global(qos: .background).async {
let getThingsResult = syncService.getThings()
DispatchQueue.main.async {
activityIndicator.stopAnimating()
updateUI(with: getThingsResult)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment