Compare commits

..

2 commits

Author SHA1 Message Date
Imbus
ce4b2c2ad8 Merge branch 'master' of git.silversoft.se:Imbus/FrostByte 2024-03-05 22:32:32 +01:00
Imbus
db402777cb Revert hack for parent_comment_id 2024-03-05 22:32:23 +01:00

View file

@ -16,7 +16,7 @@ pub async fn db_new_comment(
let insert_query = sqlx::query!( let insert_query = sqlx::query!(
"INSERT INTO comments (parent_post_id, parent_comment_id, author_user_id, content) VALUES ($1, $2, $3, $4)", "INSERT INTO comments (parent_post_id, parent_comment_id, author_user_id, content) VALUES ($1, $2, $3, $4)",
parent_post_id, parent_post_id,
parent_comment_id.unwrap_or(-1), // This is a bit of a hack parent_comment_id,
user_id, user_id,
content content
) )