| |
@@ -81,7 +81,7 @@
|
| |
if flask.g.user and not pinned:
|
| |
recent = CoprsLogic.get_multiple_owned_by_username(flask.g.user.username)
|
| |
recent = CoprsLogic.set_query_order(recent, desc=True)
|
| |
- recent = recent.limit(4)
|
| |
+ recent = recent.limit(4).all()
|
| |
|
| |
projects_count = CoprsLogic.get_multiple().count()
|
| |
# users_count = models.User.query.count()
|
| |
Our logic in
templates/coprs/show/all.html
is to show pinnedprojects if there are any. If not, show a user's recent projects if
there are any. The condition was always true though because we passed
a
flask_sqlalchemy.BaseQuery
object to the template instead of thelist of projects.