Does INShortcut fail if any integer parameter == 0?

268 views Asked by At

Siri Shortcut for custom intent. I've included several parameters, some strings, one string array, and several integers. Some of the integers are for the raw value of an enum, one's a true integer value of a app property, and one uses 0 and 1 as a Boolean.

What I'm finding is that if ANY of the integers in the intent parameters passed to the INShortcut method is 0, then INShortcut fails. As long as they are all non-0, it succeeds. fwiw, the log of the intent shows all property values to be exactly as expected, whether zero or non-zero.

print(intent)
if let shortcut = INShortcut(intent: intent) {
    let vc = INUIAddVoiceShortcutViewController(shortcut: shortcut)
    vc.delegate = self
    present(vc, animated: true)
}
else { print("INShortcut failed") }

Am I delusional? Has anyone else observed this? Is the behavior documented and I just missed it?

Thanks...

0

There are 0 answers