From 07d3bb88c7d8681f766ca8d01d203b42353898aa Mon Sep 17 00:00:00 2001 From: Jeremy Rand Date: Tue, 20 Jul 2021 19:14:08 -0400 Subject: [PATCH] Update listening state when the recognizer times out. --- ListenerApp/ContentView.swift | 2 ++ ListenerApp/Info.plist | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/ListenerApp/ContentView.swift b/ListenerApp/ContentView.swift index 93f2913..3142354 100644 --- a/ListenerApp/ContentView.swift +++ b/ListenerApp/ContentView.swift @@ -214,6 +214,8 @@ struct ContentView: View { self.recognitionRequest = nil self.recognitionTask = nil self.listening = false + guard let client = client else { return } + client.send(data: isListening()) } } diff --git a/ListenerApp/Info.plist b/ListenerApp/Info.plist index 9e0c9dc..081d6dc 100644 --- a/ListenerApp/Info.plist +++ b/ListenerApp/Info.plist @@ -17,7 +17,7 @@ CFBundleShortVersionString 1.0 CFBundleVersion - 73 + 76 LSRequiresIPhoneOS NSSpeechRecognitionUsageDescription