forked from MarseyWorld/MarseyWorld
more accurate created_utc from gumroad tx
parent
9ad113fdaa
commit
58ea68306a
|
@ -1415,13 +1415,12 @@ def gumroad():
|
||||||
print(STARS, flush=True)
|
print(STARS, flush=True)
|
||||||
abort(400)
|
abort(400)
|
||||||
|
|
||||||
print(data, flush=True)
|
|
||||||
id = data['sale_id']
|
id = data['sale_id']
|
||||||
|
|
||||||
existing = g.db.get(Transaction, id)
|
existing = g.db.get(Transaction, id)
|
||||||
if existing: return ''
|
if existing: return ''
|
||||||
|
|
||||||
created_utc = time.time()
|
created_utc = int(time.mktime(time.strptime(data['sale_timestamp'].split('.')[0], "%Y-%m-%dT%H:%M:%SZ")))
|
||||||
type = data['recurrence']
|
type = data['recurrence']
|
||||||
amount = int(data['price']) / 100
|
amount = int(data['price']) / 100
|
||||||
email = data['email']
|
email = data['email']
|
||||||
|
|
Loading…
Reference in New Issue