Merge pull request #201 from rubenvarela/fix-search_results.py

Fixed the for loop key and how to access the user name in example
This commit is contained in:
Mike Helmick 2013-05-29 08:39:10 -07:00
commit 05ca86805f

View file

@ -7,6 +7,6 @@ try:
except TwythonError as e:
print e
for tweet in search_results['results']:
print 'Tweet from @%s Date: %s' % (tweet['from_user'].encode('utf-8'), tweet['created_at'])
for tweet in search_results['statuses']:
print 'Tweet from @%s Date: %s' % (tweet['user']['screen_name'].encode('utf-8'), tweet['created_at'])
print tweet['text'].encode('utf-8'), '\n'