Enforcing async/await in synchronous methods that were marked async.

pull/1178/head
smcpeck 8 years ago
parent fa1540717b
commit a8288a93b0

@ -94,7 +94,6 @@ namespace Ombi.Api
request.AddHeader("X-Api-Key", apiKey);
request.AddJsonBody(options);
RadarrAddMovie result;
try
{
var policy = RetryHandler.RetryAndWaitPolicy((exception, timespan) => Log.Error(exception, "Exception when calling AddSeries for Sonarr, Retrying {0}", timespan), new TimeSpan[] {

@ -202,6 +202,7 @@ namespace Ombi.Core.StatusChecker
public async Task<Uri> OAuth(string url, ISession session)
{
await Task.Yield();
var csrf = StringCipher.Encrypt(Guid.NewGuid().ToString("N"), "CSRF");
session[SessionKeys.CSRF] = csrf;

@ -84,6 +84,8 @@ namespace Ombi.UI.Modules.Admin
private async Task<Response> ScheduleRun(string key)
{
await Task.Yield();
if (key.Equals(JobNames.PlexCacher, StringComparison.CurrentCultureIgnoreCase))
{
PlexContentCacher.CacheContent();

@ -47,6 +47,8 @@ namespace Ombi.UI.Modules
public async Task<Response> Netflix(string title)
{
await Task.Yield();
var result = NetflixApi.CheckNetflix(title);
if (!string.IsNullOrEmpty(result.Message))

Loading…
Cancel
Save