Skip to content
This repository has been archived by the owner on Mar 15, 2018. It is now read-only.

Commit

Permalink
add in cef logging (bug 839180)
Browse files Browse the repository at this point in the history
  • Loading branch information
Andy McKay committed Mar 7, 2013
1 parent 2d1a3e4 commit b9eb8b2
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions mkt/purchase/webpay.py
Expand Up @@ -93,6 +93,8 @@ def prepare_pay(request, addon):

jwt_ = sign_webpay_jwt(req)
log.debug('Preparing webpay JWT for addon %s: %s' % (addon, jwt_))
app_pay_cef.log(request, 'Preparing JWT', 'preparing_jwt',
'Preparing JWT for: %s' % (addon.pk), severity=3)
return {'webpayJWT': jwt_,
'contribStatusURL': reverse('webpay.pay_status',
args=[addon.app_slug, uuid_])}
Expand Down Expand Up @@ -147,6 +149,9 @@ def postback(request):
trans_id = data['response']['transactionID']
log.info('webpay postback: fulfilling purchase for contrib %s with '
'transaction %s' % (contrib, trans_id))
app_pay_cef.log(request, 'Purchase complete', 'purchase_complete',
'Purchase complete for: %s' % (contrib.addon.pk),
severity=3)
contrib.update(transaction_id=trans_id, type=amo.CONTRIB_PURCHASE)

tasks.send_purchase_receipt.delay(contrib.pk)
Expand Down

0 comments on commit b9eb8b2

Please sign in to comment.