mirror of
https://github.com/pretix/pretix.git
synced 2026-05-09 15:54:03 +00:00
PPv2: ISU-Return: explicitly set incr cache key if not set
This commit is contained in:
@@ -205,7 +205,10 @@ def isu_return(request, *args, **kwargs):
|
|||||||
# Cached access tokens are not updated by PayPal to include new Merchants that granted access rights since
|
# Cached access tokens are not updated by PayPal to include new Merchants that granted access rights since
|
||||||
# the access token was generated. Therefor we increment the cycle count and by that invalidate the cached
|
# the access token was generated. Therefor we increment the cycle count and by that invalidate the cached
|
||||||
# token and pull a new one.
|
# token and pull a new one.
|
||||||
cache.incr('pretix_paypal_token_hash_cycle')
|
try:
|
||||||
|
cache.incr('pretix_paypal_token_hash_cycle')
|
||||||
|
except ValueError:
|
||||||
|
cache.set('pretix_paypal_token_hash_cycle', 0)
|
||||||
|
|
||||||
gs = GlobalSettingsObject()
|
gs = GlobalSettingsObject()
|
||||||
prov = Paypal(event)
|
prov = Paypal(event)
|
||||||
|
|||||||
Reference in New Issue
Block a user