fix: inject post data into template context for post header row
All checks were successful
Build and Deploy / build-and-deploy (push) Successful in 36s

The post header bar needs `post` in the template context to render
the page link, feature image, and nav. Added context processor to
spread g.post_data into templates, matching the events app pattern.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
giles
2026-02-11 00:12:35 +00:00
parent 863429d51b
commit 2788e24ec8

7
app.py
View File

@@ -124,6 +124,13 @@ def create_app() -> "Quart":
abort(404)
g.market = market
@app.context_processor
async def inject_post():
post_data = getattr(g, "post_data", None)
if not post_data:
return {}
return {**post_data}
# --- Root route: market listing ---
@app.get("/")
async def markets_listing():