     // Currently, as of 2017, if you want to convert from a compressed
     // format to a pcm one, you still have to hit CoreAudio
     private func convertToPCM(completionHandler: AKConverterCallback? = nil) {
-
         guard let inputURL = self.inputURL else {
             completionHandler?(createError(message: "Input file can't be nil."))
             return


        let queue = DispatchQueue(label: "io.audiokit.AKConverter.start", qos: .utility)

        //session.progress could be sent out via a delegate for this session
        writerInput.requestMediaDataWhenReady(on: queue, using: {
            while writerInput.isReadyForMoreMediaData {

                if reader.status == .failed {
                    AKLog("Conversion Failed")
                    break

        let asset = AVURLAsset(url: inputURL)
        guard let session = AVAssetExportSession(asset: asset, presetName: AVAssetExportPresetAppleM4A) else { return }

        // session.progress could be sent out via a delegate for this session
        session.outputURL = outputURL
        session.outputFileType = .m4a
        session.exportAsynchronously {
