aboutsummaryrefslogtreecommitdiffstats
path: root/src/controllers/posts_controller.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/controllers/posts_controller.rs')
-rw-r--r--src/controllers/posts_controller.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/controllers/posts_controller.rs b/src/controllers/posts_controller.rs
index 5fdd60e..47f9ca1 100644
--- a/src/controllers/posts_controller.rs
+++ b/src/controllers/posts_controller.rs
@@ -27,10 +27,10 @@ fn create(post: Form<::models::NewPost>, conn: utils::DbConn) -> Flash<Redirect>
Flash::success(Redirect::to("/"), "Post successfully created!")
}
-#[derive(BartDisplay)]
+#[derive(BartDisplay, Serialize)]
#[template = "templates/show_post.html"]
pub struct ShowPostTemplate {
- post: ::models::Post
+ pub post: ::models::Post
}
implement_responder_for!(ShowPostTemplate);