Skip to content
This repository
Browse code

assign the list key for members instead of queues since it's members …

…that are special
  • Loading branch information...
commit f6cb108fe7ec15343d25080183cdf8eb9e70e6c3 1 parent 9afcec2
Andrew Benton andrewmbenton authored
8 lib/twilio-ruby/rest/queues.rb
... ... @@ -1,12 +1,6 @@
1 1 module Twilio
2 2 module REST
3   - class Queues < ListResource
4   - def initialize(uri, client)
5   - super
6   - # hard-code the json key since 'members' doesn't exist in the response
7   - @list_key = 'queue_members'
8   - end
9   - end
  3 + class Queues < ListResource; end
10 4
11 5 class Queue < InstanceResource
12 6 def initialize(uri, client, params={})
4 lib/twilio-ruby/rest/queues/members.rb
@@ -3,8 +3,8 @@ module REST
3 3 class Members < ListResource
4 4 def initialize(uri, client)
5 5 super
6   - # hard-code the json key since members don't have sids
7   - @instance_id_key = 'call_sid'
  6 + # hard-code the json keys since members are special
  7 + @list_key, @instance_id_key = 'queue_members', 'call_sid'
8 8 end
9 9 end
10 10

0 comments on commit f6cb108

Please sign in to comment.
Something went wrong with that request. Please try again.