code: func NewPublicDownloaderAPI(d *Downloader, m *event.TypeMux) *PublicDownloaderAPI {
  	api := &PublicDownloaderAPI{
  		d:                         d,
  		mux:                       m,
  		installSyncSubscription:   make(chan chan interface{}),
  		uninstallSyncSubscription: make(chan *uninstallSyncSubscriptionRequest),
  	}
  
  	go api.eventLoop()
  
  	return api
  }
docs: // NewPublicDownloaderAPI create a new PublicDownloaderAPI. The API has an internal event loop that
  // listens for events from the downloader through the global event mux. In case it receives one of
  // these events it broadcasts it to all syncing subscriptions that are installed through the
  // installSyncSubscription channel.