Beispiel #1
0
func movieLinks(imdbId string) []*bittorrent.Torrent {
	log.Println("Searching links for IMDB:", imdbId)

	movie := tmdb.GetMovieFromIMDB(imdbId, config.Get().Language)

	log.Printf("Resolved %s to %s\n", imdbId, movie.Title)

	searchers := providers.GetMovieSearchers()
	if len(searchers) == 0 {
		xbmc.Notify("Quasar", "LOCALIZE[30204]", config.AddonIcon())
	}

	return providers.SearchMovie(searchers, movie)
}
Beispiel #2
0
func movieLinks(tmdbId string) []*bittorrent.Torrent {
	log.Println("Searching links for:", tmdbId)

	movie := tmdb.GetMovieById(tmdbId, config.Get().Language)

	log.Printf("Resolved %s to %s", tmdbId, movie.Title)

	if torrents := InTorrentsMap(tmdbId); len(torrents) > 0 {
		return torrents
	}

	searchers := providers.GetMovieSearchers()
	if len(searchers) == 0 {
		xbmc.Notify("Quasar", "LOCALIZE[30204]", config.AddonIcon())
	}

	return providers.SearchMovie(searchers, movie)
}