public async void DeleteProfile()
{
if (SelectedProfile == null)
return;
var confirm = await
DialogService.ShowQuestionMessageBox("Delete profile",
$"Are you sure you want to delete the profile named: {SelectedProfile.Name}?\n\n" +
"This cannot be undone.");
if (!confirm.Value)
return;
ProfileProvider.DeleteProfile(SelectedProfile);
LoadProfiles();
}