Fixing issue pointed out by sk89q, wherein updateStatus() doesn't handle the in_reply_to_status_id parameter correctly.

This commit is contained in:
Ryan McGrath 2009-07-05 03:53:28 -04:00
parent 69f747a658
commit 716fe69e60
2 changed files with 2 additions and 2 deletions

View file

@ -157,7 +157,7 @@ class setup:
if len(list(status)) > 140:
print "This status message is over 140 characters, but we're gonna try it anyway. Might wanna watch this!"
try:
return simplejson.load(self.opener.open("http://twitter.com/statuses/update.json?", urllib.urlencode({"status": status}, {"in_reply_to_status_id": in_reply_to_status_id})))
return simplejson.load(self.opener.open("http://twitter.com/statuses/update.json?", urllib.urlencode({"status": status, "in_reply_to_status_id": in_reply_to_status_id})))
except HTTPError, e:
if self.debug is True:
print e.headers

View file

@ -160,7 +160,7 @@ class setup:
print("This status message is over 140 characters, but we're gonna try it anyway. Might wanna watch this!")
if self.authenticated is True:
try:
return simplejson.load(self.opener.open("http://twitter.com/statuses/update.json?", urllib.parse.urlencode({"status": status}, {"in_reply_to_status_id": in_reply_to_status_id})))
return simplejson.load(self.opener.open("http://twitter.com/statuses/update.json?", urllib.parse.urlencode({"status": status, "in_reply_to_status_id": in_reply_to_status_id})))
except HTTPError as e:
if self.debug is True:
print(e.headers)