spudtrooper/rdiorb — pull request #12 by jbaudanza (2013-02-08 00:26:46+00:00)
Title: Fixing ArgumentError in getPlaybackToken

I changed :domain into a string.

All of the keys passed into an OAuth request must be of the same type. Since 'method' was being passed a string, passing :domain as a symbol was raising the following error:

ArgumentError - comparison of Array with Array failed:
/Users/jon/.rvm/gems/ruby-1.9.2-p180/gems/oauth-0.4.7/lib/oauth/helper.rb:38:in `sort'
/Users/jon/.rvm/gems/ruby-1.9.2-p180/gems/oauth-0.4.7/lib/oauth/helper.rb:38:in `normalize'
/Users/jon/.rvm/gems/ruby-1.9.2-p180/gems/oauth-0.4.7/lib/oauth/consumer.rb:359:in `create_http_request'
/Users/jon/.rvm/gems/ruby-1.9.2-p180/gems/oauth-0.4.7/lib/oauth/consumer.rb:187:in `create_signed_request'
/Users/jon/.rvm/gems/ruby-1.9.2-p180/gems/oauth-0.4.7/lib/oauth/consumer.rb:159:in `request'
/Users/jon/.rvm/gems/ruby-1.9.2-p180/gems/oauth-0.4.7/lib/oauth/tokens/consumer_token.rb:25:in `request'
/Users/jon/.rvm/gems/ruby-1.9.2-p180/gems/oauth-0.4.7/lib/oauth/tokens/access_token.rb:12:in `request'
/Users/jon/.rvm/gems/ruby-1.9.2-p180/gems/oauth-0.4.7/lib/oauth/tokens/access_token.rb:47:in `post'
/Users/jon/.rvm/gems/ruby-1.9.2-p180/gems/rdio-0.1.0/lib/rdio/base.rb:316:in `call'
/Users/jon/.rvm/gems/ruby-1.9.2-p180/gems/rdio-0.1.0/lib/rdio/base.rb:325:in `return_object'
/Users/jon/.rvm/gems/ruby-1.9.2-p180/gems/rdio-0.1.0/lib/rdio/api.rb:233:in `getPlaybackToken'