mirror of
https://git.joinplu.me/Plume/Plume.git
synced 2024-11-23 03:51:00 +00:00
Only send notifications for mentions if the post is not a draft
This commit is contained in:
parent
b01212f4a6
commit
0200a7b223
1 changed files with 4 additions and 2 deletions
|
@ -200,8 +200,10 @@ fn update(blog: String, slug: String, user: User, conn: DbConn, data: LenientFor
|
||||||
post.update(&*conn);
|
post.update(&*conn);
|
||||||
let post = post.update_ap_url(&*conn);
|
let post = post.update_ap_url(&*conn);
|
||||||
|
|
||||||
for m in mentions.into_iter() {
|
if post.published {
|
||||||
Mention::from_activity(&*conn, Mention::build_activity(&*conn, m), post.id, true, true);
|
for m in mentions.into_iter() {
|
||||||
|
Mention::from_activity(&*conn, Mention::build_activity(&*conn, m), post.id, true, true);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
let old_tags = Tag::for_post(&*conn, post.id).into_iter().map(|t| t.tag).collect::<Vec<_>>();
|
let old_tags = Tag::for_post(&*conn, post.id).into_iter().map(|t| t.tag).collect::<Vec<_>>();
|
||||||
|
|
Loading…
Reference in a new issue