public static async Task <WebBoolResult> ProcessAsync(IOwinContext context, string scheduleId) { if (!ServiceRegistration.IsRegistered <ITvProvider>()) { throw new BadRequestException("DeleteSchedule: ITvProvider not found"); } bool result = await TVAccess.DeleteScheduleAsync(context, int.Parse(scheduleId)); return(new WebBoolResult { Result = result }); }