Relax Sync bound on Fut required on sse upgrade
async_std::spawn doesn't seem to require a Sync bound on any Futures
used on it. tide::sse::upgrade will just spawn the Future returned by
the Fn parameter. With this in mind, the Sync bound on that returned
Future seems unnecessary.
@@ -13,7 +13,7 @@ pub fn upgrade<F, Fut, State>(req: Request<State>, handler: F) -> Response
where
State: Send + Sync + 'static,
F: Fn(Request<State>, Sender) -> Fut + Send + Sync + 'static,
- Fut: Future<Output = Result<()>> + Send + Sync + 'static,
+ Fut: Future<Output = Result<()>> + Send + 'static,
{
let (sender, encoder) = async_sse::encode();
task::spawn(async move {
