thinktecture/Thinktecture.IdentityModel.45 — pull request #19 by tugberkugurlu (2013-01-20 23:36:28+00:00)
Title: Handled async method and its continuation correctly for AuthenticationHandler.SendAsync

Inside the `AuthenticationHandler.SendAsync` method, the continuation for the inner handler was scheduled to invoke without checking the status of the Task. This will cause the exception to be re-thrown if the task status is `Cancelled` or `Faulted` when trying to get to the `Result` of the task. Also, the task may already be completed. So, we don't need to schedule the continuation to be invoked.

As the project is on .NET 4.5, async/await will optimize the async code and handle it properly.