Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improved File.download #1019

Merged
merged 7 commits into from
Mar 1, 2018
Merged

Improved File.download #1019

merged 7 commits into from
Mar 1, 2018

Conversation

tsnoam
Copy link
Member

@tsnoam tsnoam commented Feb 23, 2018

  1. Added a new method File.download_as_bytearray() which returns a bytearray. Simple and straight forward for both py2 & py3.
  2. File.download() now returns a meaningful return value:
    • If download was saved to a file, return the file name.
    • If download was saved into a file-file object, return the file-like object.

Fixes #944

@tsnoam tsnoam changed the title Improved File.donwnload Improved File.download Feb 23, 2018
@tsnoam tsnoam requested a review from Eldinnie February 23, 2018 21:37
Copy link
Member

@Eldinnie Eldinnie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I pushed some small fixes for the docstrings.
The rest seems good to me.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

get_file_stream support
2 participants