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

后端 未结 5 895
难免孤独
难免孤独 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-06 00:05

    As sujjested by RaghuRam Nadiminti, by changing the WriteToStream's return type from void to Task, compilation will run successfully and you won't need the explicit casting.

    public async Task WriteToStream(Stream outputStream, HttpContent content, TransportContext context);

提交回复
热议问题