public async Task Run(int tickRate) { try { CreatePairings(); } catch (Exception x) { HandleException("Error while creating pairings: ", x); } try { var pairs = await Generate(); await SubmitPairings(pairs); } catch (Exception x) { HandleException("Error while creating pairs: ", x); } try { await emails.Flush(tickRate); } catch (Exception x) { HandleException("Error while sending emails: ", x); } }