34,333
edits
Changes
no edit summary
NSSearchPathForDirectoriesInDomains(.DocumentDirectory,
.UserDomainMask, true)
let docsDir = dirPaths[0] as ! String
let soundFilePath =
docsDir.stringByAppendingPathComponent("sound.caf")
audioRecorder = AVAudioRecorder(URL: soundFileURL,
settings: recordSettingsas [NSObject : AnyObject], error: &error)
if let err = error {