What is different with PushStreamContent between web api & web api 2?

后端 未结 5 818
难免孤独
难免孤独 2021-02-05 23:34

I\'ve created two identical web api projects, one in VS 2012 and another in VS 2013, both targeting the 4.5 .net framework. The projects are based on Filip W\'s video download t

5条回答
  •  借酒劲吻你
    2021-02-05 23:40

    This was my workaround: if the call was ambiguous, just cast it:

    response.Content = new PushStreamContent(
        (Action) video.WriteToStream,
    new MediaTypeHeaderValue("video/" + ext));
    

提交回复
热议问题