Class: Play::Artist
- Inherits:
-
ActiveRecord::Base
- Object
- ActiveRecord::Base
- Play::Artist
- Defined in:
- lib/play/artist.rb
Instance Method Summary collapse
-
#enqueue!(user) ⇒ Object
Queue up an artist.
Instance Method Details
#enqueue!(user) ⇒ Object
Queue up an artist. This will grab ten random tracks for this artist and queue ‘em up.
user - the User who is requesting the artist be queued
Returns nothing.
13 14 15 16 17 18 |
# File 'lib/play/artist.rb', line 13 def enqueue!(user) songs.shuffle[0..9].collect do |song| song.enqueue!(user) song end end |