I noticed a weird trait restriction that makes it so only streams implementing Sync are permitted to the upload API. Even though the download API doesn't abide by those same rules.
Effectively makes it so you can't pipe the output of, say.. cat into add. Because add expects more than cat can offer.
And this will be the case most of the time. I looked under the hood, and couldn't find any reasons why the stream itself needs to be Sync.
So this PR gets rid of all the Sync bounds where they are present.
Tested locally against the unit tests, as well as in my own project, and it all checks out.
Linked: https://github.com/ferristseng/rust-multipart-rfc7578/pull/33
I noticed a weird trait restriction that makes it so only streams implementing
Sync
are permitted to the upload API. Even though the download API doesn't abide by those same rules.Effectively makes it so you can't pipe the output of, say..
cat
intoadd
. Becauseadd
expects more thancat
can offer.And this will be the case most of the time. I looked under the hood, and couldn't find any reasons why the stream itself needs to be
Sync
.So this PR gets rid of all the
Sync
bounds where they are present.Tested locally against the unit tests, as well as in my own project, and it all checks out.