code: func (ss *SQLSubStore) Close() error {
  	ss.Lock()
  	if ss.closed {
  		ss.Unlock()
  		return nil
  	}
  	// Flush before switching the state to closed.
  	err := ss.flush()
  	ss.closed = true
  	ss.Unlock()
  	return err
  }
docs: // Close implements the SubStore interface