Skip to content

Commit

Permalink
Merge pull request #1055 from RyanTsang/master
Browse files Browse the repository at this point in the history
Fix issue #1054
  • Loading branch information
farirat authored Aug 3, 2022
2 parents eed251e + ab449f0 commit c090977
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions jasmin/protocols/rest/tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,15 +95,15 @@ def httpapi_send(self, batch_id, batch_config, message_params, config):

# Return status back
if r.status_code != 200:
logger.error('[%s] %s' % (batch_id, r.content.strip('"')))
logger.error('[%s] %s' % (batch_id, r.text.strip('"')))
if batch_config.get('errback_url', None):
batch_callback.delay(
batch_config.get('errback_url'), batch_id, message_params['to'], 0,
'HTTPAPI error: %s' % r.content.strip('"'))
'HTTPAPI error: %s' % r.text.strip('"'))
else:
if batch_config.get('callback_url', None):
batch_callback.delay(
batch_config.get('callback_url'), batch_id, message_params['to'], 1, r.content)
batch_config.get('callback_url'), batch_id, message_params['to'], 1, r.text)


@task(bind=True, base=JasminTask)
Expand Down

0 comments on commit c090977

Please sign in to comment.