Skip to content
Snippets Groups Projects
Commit c9074d7d authored by Goffin Simon's avatar Goffin Simon
Browse files

[FIX] payment_stripe_checkout_webhook: Json request not available


Json request was not availalble since it's not a json rpc request from Odoo
but a request from Stripe

opw:2449738

closes odoo/odoo#73975

Signed-off-by: default avatarAntoine Vandevenne (anv) <AntoineVDV@users.noreply.github.com>
parent 5372beda
No related branches found
No related tags found
No related merge requests found
# -*- coding: utf-8 -*-
import json
import logging
from odoo.http import request
......@@ -12,5 +13,6 @@ class StripeController(http.Controller):
@http.route('/payment/stripe/webhook', type='json', auth='public', csrf=False)
def stripe_webhook(self, **kwargs):
request.env['payment.acquirer'].sudo()._handle_stripe_webhook(request.jsonrequest)
data = json.loads(request.httprequest.data)
request.env['payment.acquirer'].sudo()._handle_stripe_webhook(data)
return 'OK'
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment