whoops!!!! whoops
This commit is contained in:
parent
278c5b9e2b
commit
c897edf294
11
lib/json.py
11
lib/json.py
|
@ -1,6 +1,13 @@
|
||||||
from json import dumps
|
from json import dumps
|
||||||
|
|
||||||
|
|
||||||
def account(acc):
|
def account(acc):
|
||||||
|
last_delete = None
|
||||||
|
next_delete = None
|
||||||
|
if acc.last_delete:
|
||||||
|
last_delete = acc.last_delete.isoformat()
|
||||||
|
if acc.next_delete:
|
||||||
|
next_delete = acc.next_delete.isoformat()
|
||||||
return dumps(dict(
|
return dumps(dict(
|
||||||
post_count=acc.post_count(),
|
post_count=acc.post_count(),
|
||||||
eligible_for_delete_estimate=acc.estimate_eligible_for_delete(),
|
eligible_for_delete_estimate=acc.estimate_eligible_for_delete(),
|
||||||
|
@ -10,6 +17,6 @@ def account(acc):
|
||||||
id=acc.id,
|
id=acc.id,
|
||||||
service=acc.service,
|
service=acc.service,
|
||||||
policy_enabled=acc.policy_enabled,
|
policy_enabled=acc.policy_enabled,
|
||||||
next_delete=acc.next_delete.isoformat(),
|
next_delete=next_delete,
|
||||||
last_delete=acc.last_delete.isoformat(),
|
last_delete=last_delete,
|
||||||
))
|
))
|
||||||
|
|
Loading…
Reference in New Issue