Skip to content

Open source Grok Bot alternative, Bring your own agent and subscription: message Claude Code, Codex, Gemini CLI, Cursor, Copilot and 40+ AI agents as bots on your own computer, from iPhone, Mac, Windows, Linux or terminal. Agent-agnostic and free. Also a Muse and Dots alternative. Built in Rust.

fix(ios): stop dictation without opening the audio unit it never started

leepokai43a204d7c189
diff --git a/apps/ios/Kit/Sources/CodyncUI/Thread/Dictation.swift b/apps/ios/Kit/Sources/CodyncUI/Thread/Dictation.swift
index c2e80afd..cee808b7 100644
--- a/apps/ios/Kit/Sources/CodyncUI/Thread/Dictation.swift
+++ b/apps/ios/Kit/Sources/CodyncUI/Thread/Dictation.swift
@@ -131,11 +131,14 @@ final class Dictation {
recording = nil
transcribing = false
edit = nil
- // Only a microphone that was opened: touching `inputNode` starts the audio system (on every send and chat
- // change), and on a busy simulator its start can time out and abort the process.
+ // Only a running engine: touching `inputNode` starts the audio system (on every send and chat change), and on
+ // a busy simulator its start can time out and abort the process. A tap left on a stopped engine is replaced
+ // when the microphone opens again.
if listening {
- engine.inputNode.removeTap(onBus: 0)
- if engine.isRunning { engine.stop() }
+ if engine.isRunning {
+ engine.inputNode.removeTap(onBus: 0)
+ engine.stop()
+ }
try? AVAudioSession.sharedInstance().setActive(false, options: .notifyOthersOnDeactivation)
}
listening = false