/// <summary> /// Called after the GetPersonas method, takes the persona objects and puts them into a PersonaContainer object that holds 2 persona /// objects then adds this container object to the pairedPersonas list. This is necessary in order to display the personas in a /// 2 column list. /// </summary> /// <return>None</return> private async void updatePairedPersonas() { try { pairedPersonas.Clear(); await userPersonas.PopulatePersonasFromBackend().ConfigureAwait(true); personas = userPersonas.GetAllPersonas(); for (int i = 0; i < personas.Count; i += 2) { if (i + 1 < personas.Count) { this.pairedPersonas.Add(new PersonaContainer(personas[i], personas[i + 1])); } else { this.pairedPersonas.Add(new PersonaContainer(personas[i])); } } } catch (BadBackendRequestException e) { errorHandler(e); } }