Closed miraculixx closed 7 years ago
Hi @miraculixx,
Great idea! you're very much welcome to send me a PR for this and i'll review and merge if this feature is needed on your end.
I would rather have it delete the Device as is the default action taken when a device token is invalidated.
This has been implemented to delete the invalid token rather than keeping it. PR: https://github.com/rakanalh/django-pushy/pull/41 which contains some refactorings also applies this.
apns offers a feedback mechanism to get reports on bad device tockens. This should be automated so that invalid tokens can be deleted automatically (or better: marked as invalid so we can send users a reminder email):
Required changes:
Device
with statesVALID
,INVALID
Projects using
django-pushy
can then add this celery task as a daily scheduled task, thus automating device management.