turntabler 0.3.2 → 0.3.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # master
2
2
 
3
+ ## 0.3.3 / 2013-03-18
4
+
5
+ * Fix Preferences#update not validating options properly
6
+ * Update User#load to use the new user.get_profile API parameters
7
+ * Update Song#skip to use the new room.stop_song API parameters
8
+
3
9
  ## 0.3.2 / 2013-02-24
4
10
 
5
11
  * Fix songs being added to the wrong playlist when played by other djs
@@ -17,7 +17,7 @@ GEM
17
17
  faye-websocket (0.4.6)
18
18
  eventmachine (>= 0.12.0)
19
19
  http_parser.rb (0.5.3)
20
- turntabler (0.3.2)
20
+ turntabler (0.3.3)
21
21
  em-http-request
22
22
  em-synchrony
23
23
  faye-websocket
@@ -13,7 +13,10 @@ module Turntabler
13
13
  # @return [Boolean]
14
14
  attribute :active, :load => false
15
15
 
16
- # The songs that have been added to this playlist
16
+ # The songs that have been added to this playlist. Songs will be listed in
17
+ # the order that they will be played. If the user is currently playing, then
18
+ # that song will be listed last since it has been removed from the top of
19
+ # the queue by Turntable.
17
20
  # @return [Array<Turntabler::Song>]
18
21
  attribute :songs, :list do |songs|
19
22
  songs.map {|attrs| Song.new(client, attrs.merge(:playlist => id))}
@@ -62,7 +62,7 @@ module Turntabler
62
62
  # @example
63
63
  # preferences.update(:notify_dj => false) # => true
64
64
  def update(attributes = {})
65
- assert_valid_values(attributes, :notify_dj, :notify_fan, :notify_news, :notify_random, :facebook_awesome, :facebook_join, :facebook_dj)
65
+ assert_valid_keys(attributes, :notify_dj, :notify_fan, :notify_news, :notify_random, :facebook_awesome, :facebook_join, :facebook_dj)
66
66
  api('user.edit_prefs', attributes)
67
67
  self.attributes = attributes
68
68
  true
@@ -144,7 +144,7 @@ module Turntabler
144
144
  # song.skip # => true
145
145
  def skip
146
146
  assert_current_song
147
- api('room.stop_song', :roomid => room.id, :section => room.section)
147
+ api('room.stop_song', :songid => id, :djid => played_by.id, :roomid => room.id, :section => room.section)
148
148
  true
149
149
  end
150
150
 
@@ -82,7 +82,7 @@ module Turntabler
82
82
  # user.load # => true
83
83
  # user.laptop_name # => "chrome"
84
84
  def load
85
- data = api('user.get_profile', :userid => id)
85
+ data = api('user.get_profile', :profileid => id)
86
86
  self.attributes = data
87
87
  super
88
88
  end
@@ -3,7 +3,7 @@ module Turntabler
3
3
  module Version
4
4
  MAJOR = 0
5
5
  MINOR = 3
6
- PATCH = 2
6
+ PATCH = 3
7
7
  STRING = [MAJOR, MINOR, PATCH].join(".")
8
8
  end
9
9
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: turntabler
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.2
4
+ version: 0.3.3
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-02-24 00:00:00.000000000 Z
12
+ date: 2013-03-19 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: em-synchrony
@@ -195,4 +195,3 @@ signing_key:
195
195
  specification_version: 3
196
196
  summary: Turntable.FM API for Ruby
197
197
  test_files: []
198
- has_rdoc: