public ResponseContract RegisterClient(ClientDTO client) { ResponseContract response = new ResponseContract(); try { Client newClient = client.MapTo(); ClientBusiness clientBLL = new ClientBusiness(); string error = clientBLL.RegisterClient(newClient); if (!string.IsNullOrWhiteSpace(error)) response.ErrorMessage = error; } catch (Exception ex) { response.ErrorMessage = ex.Message; } return response; }