public static void InitAdmin() { string role = "Админ"; User admin = new User { ID = 1, Login = "******", Password = "******", Email = "*****@*****.**", RegistrationDate = DateTime.Now }; try { _userLogic.InitialAdmin(admin, role); } catch (OperationCanceledException ex) { Logger.LogShortErrorInfo(ex); _roleLogic.Add(new Role { ID = 1, Title = role }); _userLogic.InitialAdmin(admin, role); } }