public bool Update(string oldName, IDishContainerDAL dal = null) { if (ExistsInDatabase(this.Name, dal) && this.Name != oldName) { return(false); } if (!ExistsInDatabase(oldName, dal)) { return(false); } this.Price = (float)Math.Round(this.Price, 2); if (this.Price < 0) { return(false); } return(dishDAL.Update(oldName, this.Name, this.Price, this.IngredentDTOs)); }