Fix temporary file deletion timing

This commit is contained in:
Beingpax 2025-05-02 09:21:39 +05:45
parent 5f1662ab30
commit 0f70d9fc05

View File

@ -395,8 +395,6 @@ class WhisperState: NSObject, ObservableObject, AVAudioRecorderDelegate {
let fileName = "\(UUID().uuidString).wav"
let permanentURL = recordingsDirectory.appendingPathComponent(fileName)
try FileManager.default.copyItem(at: tempURL, to: permanentURL)
try? FileManager.default.removeItem(at: tempURL)
return permanentURL
}
}