title: Uploading video to Firebase Storage Error Swift
body: <p>I am trying to upload a video to Firebase Storage but I am getting the following error...</p>
  
  <pre><code>*** Assertion failure in -[FIRStorageUploadTask enqueue], /Users/.../Documents/.../.../Pods/FirebaseStorage/Firebase/Storage/FIRStorageUploadTask.m:73
  </code></pre>
  
  <p>I am able to upload images to Storage perfectly fine, and I am able to save the video to the phones camera roll perfectly.</p>
  
  <p>Here is my code...</p>
  
  <pre><code>compressVideoWithOverlay(inputURL: videoURL, quality: AVAssetExportPreset640x480) { (exportSession) in
          guard let storyVideoUrl = exportSession?.outputURL else { return }
  
          let videoName = NSUUID().uuidString
          guard let uid = Auth.auth().currentUser?.uid else { return }
  
          let storageRef = Storage.storage().reference().child(uid).child("stories").child("\(videoName).mp4")
  
          storageRef.putFile(from: storyVideoUrl, metadata: nil, completion: { (metadata, error) in
  
              if error != nil {
                  print(error!)
                  self.stopActivityIndicatorWithMessage(completionMessage: R.string.stories.loadingMessageError())
                  self.hideToolbar(hide: false)
                  return
              }...
  </code></pre>
  
  <p>The error is returned on </p>
  
  <pre><code>storageRef.putFile(from: storyVideoUrl, metadata: nil, completion: { (metadata, error) in
  </code></pre>
  
  <p>I have also tried putData and get the same error.</p>
  
  <p>compressVideoWithOverlay() returns a fileURL which seems to be working fine as I use that same URL to save to the camera roll.</p>
  
  <p>Any ideas on why this is happening?</p>
  
  <p>Thanks</p>