protected virtual void Dispose(bool disposing) { if (disposing && Session != null && ShouldDisposeSession) { Session.Dispose(); } _disposed = true; unitOfWork = null; }
public UserStore(IUnitOfWorkIdentity unitOfWork) { if (unitOfWork == null) { throw new ArgumentNullException("unitOfWork"); } ShouldDisposeSession = true; this.unitOfWork = (UnitOfWorkIdentity)unitOfWork; }