Created
October 8, 2018 21:58
-
-
Save shiningabdul/e234c013a79082d335a474ad295aed3f to your computer and use it in GitHub Desktop.
Updated view controller to donate shortcut
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@IBAction func showButtonTapped(_ sender: Any) { | |
guard let newMessage = messageField.text else { | |
return | |
} | |
messageLabel.text = newMessage | |
let intent = IntentManager.shared.intent(withMessage: newMessage) | |
IntentManager.shared.donateShortcuts(withIntent: intent) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment