public bool Add(string profile) { Guid _profId = new Guid(); if (string.IsNullOrWhiteSpace(profile)) { throw new ArgumentNullException("profile id is empty"); } if (!Guid.TryParse(profile, out _profId)) { throw new Exception("profile id is invalid"); } //create a new profile obj and provide the updated values from the body being sent. Profile result = new Profile(); result.ProfileId = _profId.ToString(); return(_profileDal.Add(result)); }
public bool Add(Profile profile) { return(_profileDal.Add(profile)); }