projects
/
oweals
/
karmaworld.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
135a43c
)
#388 ensure self.slug is not the empty string
author
Bryan Bonvallet
<btbonval@gmail.com>
Tue, 13 Jan 2015 19:27:19 +0000
(14:27 -0500)
committer
Bryan Bonvallet
<btbonval@gmail.com>
Tue, 13 Jan 2015 19:27:19 +0000
(14:27 -0500)
karmaworld/apps/notes/models.py
patch
|
blob
|
history
diff --git
a/karmaworld/apps/notes/models.py
b/karmaworld/apps/notes/models.py
index 8710af7f096678dd83f5d2d0fcbf8471512add7a..c6c2a52aad0c9d7b5bb1815ce70c145511bdb744 100644
(file)
--- a/
karmaworld/apps/notes/models.py
+++ b/
karmaworld/apps/notes/models.py
@@
-299,7
+299,7
@@
class Note(Document):
""" Resolve note url, use 'note' route and slug if slug
otherwise use note.id
"""
- if self.slug
is not None
:
+ if self.slug:
# return a url ending in slug
if self.course.school:
return reverse('note_detail', args=[self.course.school.slug, self.course.slug, self.slug])