Skip to content
This repository was archived by the owner on Feb 27, 2019. It is now read-only.

Conversation

@dewski
Copy link
Owner

@dewski dewski commented Apr 18, 2012

Just starting the renaming so it'll be ready if we decide to change the module name.

@stve
Copy link
Collaborator

stve commented May 8, 2012

On the subject of breaking changes, what do you think about removing the .results object from the response. Currently it works like this:

songs = itunes.music('green day she')
songs.results.each do |song|
  puts "#{song.track_name} - #{song.artist_name} (#{song.collection_name})"
end

I don't think the result payloads include anything worth keeping (AFAIK just a result_count which is basically the same thing as songs.size) so we could just do this instead:

songs = itunes.music('green day she')
songs.each do |song|
  puts "#{song.track_name} - #{song.artist_name} (#{song.collection_name})"
end

@stve
Copy link
Collaborator

stve commented May 8, 2012

Do you have other music services in mind to add to this?

@dewski
Copy link
Owner Author

dewski commented May 13, 2012

I was thinking Spotify or Last.fm would be good additions. That way you could search multiple databases (with the obvious overhead of multiple requests).

> Tunes.sources
# => [Tunes::Source::ITunes, Tunes::Source::Spotify, Tunes::Source::LastFm]
> Tunes.sources = :spotify
> Tunes.sources
# => [Tunes::Source::Spotify]
> Tunes.sources << :lastfm
# => [Tunes::Source::Spotify, Tunes::Source::LastFm]

@stve
Copy link
Collaborator

stve commented May 13, 2012

Sweet! This was actually one of my original motivators with this gem. In particular, I wanted to be able to search across iTunes and Amazon for availability/price. I could see a similar desire to do so with Spotify/Rdio/etc.

@tboyko
Copy link

tboyko commented Sep 26, 2012

+1 for @spagalloco point on "flattening" .results!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants