remove debug log for post creation

This commit is contained in:
Felix Ableitner 2020-04-07 19:13:33 +02:00
parent b7103a7e14
commit d3bd7771d2
1 changed files with 0 additions and 2 deletions

View File

@ -111,13 +111,11 @@ impl Crud<PostForm> for Post {
fn create(conn: &PgConnection, new_post: &PostForm) -> Result<Self, Error> {
use crate::schema::post::dsl::*;
dbg!(&new_post);
insert_into(post).values(new_post).get_result::<Self>(conn)
}
fn update(conn: &PgConnection, post_id: i32, new_post: &PostForm) -> Result<Self, Error> {
use crate::schema::post::dsl::*;
dbg!(&new_post);
diesel::update(post.find(post_id))
.set(new_post)
.get_result::<Self>(conn)