code: func (ps *Store) Add(p *v2.Plugin) error {
  	ps.Lock()
  	defer ps.Unlock()
  
  	if v, exist := ps.plugins[p.GetID()]; exist {
  		return fmt.Errorf("plugin %q has the same ID %s as %q", p.Name(), p.GetID(), v.Name())
  	}
  
  	ps.setSpecOpts(p)
  
  	ps.plugins[p.GetID()] = p
  	return nil
  }
docs: // Add adds a plugin to memory and plugindb.
  // An error will be returned if there is a collision.