mirror of
https://github.com/Hopiu/django-notifications.git
synced 2026-04-25 23:44:46 +00:00
Merge pull request #61 from philroche/master
Add __str__ to Notification Model to support Python 3
This commit is contained in:
commit
b8806e07bb
2 changed files with 4 additions and 0 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
|
@ -5,3 +5,4 @@ dist
|
|||
MANIFEST
|
||||
.coverage
|
||||
htmlcov
|
||||
/.idea/
|
||||
|
|
|
|||
|
|
@ -211,6 +211,9 @@ class Notification(models.Model):
|
|||
return u'%(actor)s %(verb)s %(action_object)s %(timesince)s ago' % ctx
|
||||
return u'%(actor)s %(verb)s %(timesince)s ago' % ctx
|
||||
|
||||
def __str__(self):#Adds support for Python 3
|
||||
return self.__unicode__()
|
||||
|
||||
def timesince(self, now=None):
|
||||
"""
|
||||
Shortcut for the ``django.utils.timesince.timesince`` function of the
|
||||
|
|
|
|||
Loading…
Reference in a new issue