Skip to content

Commit

Permalink
[rostwitter] Fix _check_post_request (#7)
Browse files Browse the repository at this point in the history
  • Loading branch information
nakane11 authored and knorth55 committed Jan 27, 2023
1 parent bda5759 commit d6fffa3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion rostwitter/python/rostwitter/twitter.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,8 @@ def _request_url(self, url, verb, data=None):

def _check_post_request(self, request):
valid = True
data = simplejson.loads(request.content)
if request.status_code != 200:
data = simplejson.loads(request.content)
rospy.logwarn('post tweet failed. status_code: {}'
.format(request.status_code))
if 'errors' in data:
Expand Down

0 comments on commit d6fffa3

Please sign in to comment.