-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Implement optional io.Reader in AudioRequest (#303) (#265) #331
Implement optional io.Reader in AudioRequest (#303) (#265) #331
Conversation
Codecov Report
@@ Coverage Diff @@
## master #331 +/- ##
==========================================
+ Coverage 92.36% 93.05% +0.68%
==========================================
Files 19 18 -1
Lines 655 648 -7
==========================================
- Hits 605 603 -2
+ Misses 37 33 -4
+ Partials 13 12 -1
|
It'd be nice to include this feature in the Files Upload, Image Edit, and Image Variation endpoints as well |
@mdarc thank you for the PR! Would love to merge it once the test coverage issue is fixed |
Coverage issue fixed. (and np! I'm glad to contribute) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you so much!
This change adds an optional
io.Reader
to theAudioRequest
structure. This addition makes this structure more versatile and allows you to use a different source other than an existing file from your filesystem. It also maintaining backwards compatibility.I'd be glad to implement the same logic for the other Request types (
FileRequest
,ImageEditRequest
,ImageVariRequest
) in preferably subsequent PR's.