   private var isAudioSetup: Bool = false
 
   private var useAudio: Bool {
-    return self.options.useMicrophone && AVAudioSession.sharedInstance().recordPermission() == .granted && isAudioSetup
+    return options.useMicrophone && AVAudioSession.sharedInstance().recordPermission() == .granted && isAudioSetup
   }
   private var videoFramesWritten: Bool = false
   private var waitingForPermissions: Bool = false


    isRecording = false
    isPrepared = false
    isAudioSetup = false
    videoFramesWritten = false

    currentTime = kCMTimeInvalid

    do {
      try recordingSession.setCategory(AVAudioSessionCategoryPlayAndRecord)
      try recordingSession.setActive(true)
      recordingSession.requestRecordPermission() { allowed in
        DispatchQueue.main.async {
          if allowed {
            self.options.useMicrophone = true
          } else {
            self.options.useMicrophone = false
          }
        }
      }
      isAudioSetup = true
    } catch {
      self.options.useMicrophone = false
    }

  }
