protected override void Dispose(bool disposing) { if (disposing) { _repository.Dispose(); } base.Dispose(disposing); }
public virtual void Dispose(bool disposing) { if (!this.disposed) { if (disposing) { userManager.Dispose(); roleManager.Dispose(); studentRepository.Dispose(); studyRepository.Dispose(); } this.disposed = true; } }