Fix templates issues

This commit is contained in:
Thomas Sileo
2019-04-15 21:20:14 +02:00
parent b3c3ab0b03
commit 395fec012b
2 changed files with 38 additions and 36 deletions

3
app.py
View File

@@ -812,6 +812,7 @@ def index():
"meta.undo": False,
"$or": [{"meta.pinned": False}, {"meta.pinned": {"$exists": False}}],
}
print(list(DB.activities.find(q)))
pinned = []
# Only fetch the pinned notes if we're on the first page
@@ -2966,7 +2967,7 @@ def task_cleanup_part_1():
DB.activities.update_many(
{
"box": Box.OUTBOX.value,
"type": ActivityType.CREATE.value,
"type": {"$in": [ActivityType.CREATE.value, ActivityType.ANNOUNCE.value]},
"meta.public": {"$exists": False},
},
{"$set": {"meta.public": True}},