public bool CreateServer(ServerModel model) { //return System.Operation.Create(() => //{ var isExists = _context.Servers.Where(c => c.ServerID == model.ServerID).FirstOrDefault(); if (isExists != null) { throw new Exception("user email already exist"); } var entity = model.Create(model); _context.Servers.Add(entity); _context.SaveChanges(); return(true); //}); }