Skip to content

Commit

Permalink
tweaking to be consistent with naming conventions, etc
Browse files Browse the repository at this point in the history
  • Loading branch information
Matthew A. Russell committed Jan 28, 2011
1 parent 747e3da commit 4542830
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions recipe__get_friends_followers.py
Expand Up @@ -18,19 +18,19 @@
# You could call make_twitter_request(t, t.friends.ids, *args, **kw) or
# use functools to "partially bind" a new callable with these parameters

getFriendIds = functools.partial(make_twitter_request, t, t.friends.ids)
get_friends_ids = functools.partial(make_twitter_request, t, t.friends.ids)

# Ditto
# Ditto if you want to do the same thing to get followers...

getFollowerIds = functools.partial(make_twitter_request, t, t.followers.ids)
# getFollowerIds = functools.partial(make_twitter_request, t, t.followers.ids)

cursor = -1
ids = []
while cursor != 0:

# Use make_twitter_request via the partially bound callable...

response = getFriendIds(screen_name=SCREEN_NAME, cursor=cursor)
response = get_friends_ids(screen_name=SCREEN_NAME, cursor=cursor)
ids += response['ids']
cursor = response['next_cursor']

Expand Down

0 comments on commit 4542830

Please sign in to comment.