projects
/
zzz-floof.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Added partial support for comment threading.
[zzz-floof.git]
/
floof
/
lib
/
helpers.py
diff --git
a/floof/lib/helpers.py
b/floof/lib/helpers.py
index
c8a1251
..
1c2f0c1
100644
(file)
--- a/
floof/lib/helpers.py
+++ b/
floof/lib/helpers.py
@@
-31,3
+31,9
@@
def get_object_or_404(model, **kw):
abort(404)
return obj
abort(404)
return obj
+def get_comment_owner_url(**route):
+ """Given a view route, returns the owner_url route parameter for generating
+ comment URLs.
+ """
+ # url() returns URLs beginning with a slash. We just need to strip it.
+ return url(**route)[1:]