title: Dropbox - App folder deleted - getting NSURLErrorRequestBodyStreamExhausted error - iOS
body: <p>I am using Core API for integrating dropbox with an iOS app. I am able to authenticate an account, and successfully upload files.</p>
  
  <p>But say after authentication, user deletes the app folder from the dropbox account, or uninstalls the app through dropbox settings.</p>
  
  <p>After that if I try to upload a file, the whole file gets uploaded (progress reaches from 0 to 1) and then I receive an error with error code <code>-1021</code> which corresponds to <code>NSURLErrorRequestBodyStreamExhausted</code>, and nor error code <code>401</code> according to Standard API errors in <a href="https://www.dropbox.com/developers/core/api" rel="nofollow">https://www.dropbox.com/developers/core/api</a>.<br>
  The issue is that this is happening on devices with iOS 6, even the account is not unlinked by itself.
  I have a device with iOS 5, which gets an error code of <code>401</code> (but that too after the whole file has been uploaded), which is authentication error (error code 401) as explained in core api docs. And the account gets unlinked by itself.</p>
  
  <p><strong>Update:</strong> This bug has been solved in the latest dropbox core api Build.</p>