Open
Description
IDISP013 triggers in the following situation:
private async Task IDISP013()
{
using var client = new HttpClient();
Func<Task<HttpResponseMessage>> f = () => client.GetAsync("");
// ^^^^^^^^^^^^^^^^^^^ Await in using
await f();
}
I believe this to be a false positive, as f
is executed within the scope of the using
. -- When f
wasn't awaited I can see there being an issue where client
would've been disposed before GetAsync
finished.
Metadata
Metadata
Assignees
Labels
No labels