EfRepository.cs - Why are some lines commented out in the source code?

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
12 years ago
Specifically, why are the following lines commented out?


        public void Update(T entity)
        {
            if (entity == null)
                throw new ArgumentNullException("entity");

            //if (!this._context.IsAttached(entity))
            //    this._entities.Attach(entity);

            this._context.SaveChanges();
        }

        public void Delete(T entity)
        {
            if (entity == null)
                throw new ArgumentNullException("entity");

            //if (!this._context.IsAttached(entity))
            //    this._entities.Attach(entity);

            this._entities.Remove(entity);

            this._context.SaveChanges();
        }
12 years ago
Because they're not required
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.