rakanalh / django-pushy

Your push notifications handled at scale.
MIT License
168 stars 16 forks source link

Update models.py for compatibility with Django 2.0 #42

Open helb opened 7 years ago

helb commented 7 years ago

on_delete will be mandatory in Django 2.0:

File "…/site-packages/pushy/models.py", line 74, in Device
    user = models.ForeignKey(settings.AUTH_USER_MODEL, blank=True, null=True)
TypeError: __init__() missing 1 required positional argument: 'on_delete'
rakanalh commented 7 years ago

Hello @helb,

Thank you so much for the PR. Would you be so kind and resolve the CI errors in travis?

pushy/models.py:74:80: E501 line too long (98 > 79 characters)

Also, please make sure to add "django==2.0.0" after the following line: https://github.com/rakanalh/django-pushy/blob/master/.travis.yml#L13