Skip to content

Instantly share code, notes, and snippets.

@tibbon
Created November 29, 2012 23:34
Show Gist options
  • Save tibbon/4172664 to your computer and use it in GitHub Desktop.
Save tibbon/4172664 to your computer and use it in GitHub Desktop.
Non-working Twitter Method
def friends(*args)
options = extract_options!(args)
merge_default_cursor!(options)
users_from_response(:get, "/1.1/friends/list.json", options)
end
1) Twitter::API::FriendsAndFollowers#friends with a screen_name passed requests the correct resource
Failure/Error: @client.friends("sferik")
NoMethodError:
undefined method `last' for {:cursor=>-1}:Hash
# ./lib/twitter/api/utils.rb:128:in `extract_options!'
# ./lib/twitter/api/utils.rb:83:in `users_from_response'
# ./lib/twitter/api/friends_and_followers.rb:313:in `friends'
# ./spec/twitter/api/friends_and_followers_spec.rb:472:in `block (4 levels) in <top (required)>'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment