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

Use Readable instead of ReadStream in uploadV2 #1577

Merged
merged 1 commit into from Feb 1, 2023

Conversation

redneb
Copy link
Contributor

@redneb redneb commented Dec 29, 2022

Summary

The old upload method accepts a Readable for its file argument, but the new uploadV2 accepts a ReadStream. There is no reason to use ReadStream here: Readable is strictly more generic (it's a superclass of ReadStream) and the code actually does not use any functionality specific to ReadStream, it only uses methods and events from Readable. This will make the transition from upload to uploadV2 more easy.

Requirements (place an x in each [ ])

@CLAassistant
Copy link

CLAassistant commented Dec 29, 2022

CLA assistant check
All committers have signed the CLA.

@seratch seratch added semver:patch enhancement M-T: A feature request for new functionality pkg:web-api applies to `@slack/web-api` labels Dec 29, 2022
@seratch seratch added this to the web-api@6.8.1 milestone Dec 29, 2022
@seratch seratch requested review from seratch and zimeg January 31, 2023 00:48
@filmaj filmaj merged commit a4c530d into slackapi:main Feb 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement M-T: A feature request for new functionality pkg:web-api applies to `@slack/web-api` semver:patch
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants