From ab4af10ce5d20172a48f21775a0226a8b98321fb Mon Sep 17 00:00:00 2001 From: Bat Date: Thu, 26 Jul 2018 19:10:50 +0200 Subject: [PATCH] Fix a simlar bug on blog pages --- src/routes/blogs.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/routes/blogs.rs b/src/routes/blogs.rs index 39df22a0..662687fe 100644 --- a/src/routes/blogs.rs +++ b/src/routes/blogs.rs @@ -28,7 +28,7 @@ fn paginated_details(name: String, conn: DbConn, user: Option, page: Page) let authors = &blog.list_authors(&*conn); Template::render("blogs/details", json!({ - "blog": &blog, + "blog": &blog.to_json(&*conn), "account": user, "is_author": user.map(|x| x.is_author_in(&*conn, blog.clone())), "posts": posts.into_iter().map(|p| p.to_json(&*conn)).collect::>(),