projects
/
zzz-spline-forum.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
17e9ab6
)
Make Post.author an innerjoin.
veekun-promotions/2010101501
veekun-promotions/2010101701
author
Eevee
<git@veekun.com>
Sun, 26 Sep 2010 04:52:46 +0000
(21:52 -0700)
committer
Eevee
<git@veekun.com>
Sun, 26 Sep 2010 04:52:46 +0000
(21:52 -0700)
splinext/forum/model/__init__.py
patch
|
blob
|
history
diff --git
a/splinext/forum/model/__init__.py
b/splinext/forum/model/__init__.py
index
c913561
..
b8f9225
100644
(file)
--- a/
splinext/forum/model/__init__.py
+++ b/
splinext/forum/model/__init__.py
@@
-87,4
+87,4
@@
Thread.first_post = relation(Post, primaryjoin=and_(Post.thread_id == Thread.id,
# XXX THIS WILL NEED TO CHANGE when posts can be deleted! Or change what 'position' means
Thread.last_post = relation(Post, primaryjoin=and_(Post.thread_id == Thread.id, Post.position == Thread.post_count), foreign_keys=[Post.thread_id], innerjoin=True, uselist=False, viewonly=True)
-Post.author = relation(users_model.User, backref='posts')
+Post.author = relation(users_model.User, backref='posts'
, innerjoin=True
)