mirror of
https://gitlab.com/comunic/comunicapiv3
synced 2025-06-21 00:45:18 +00:00
Delete all notifications about a post when making it private
This commit is contained in:
@ -403,7 +403,7 @@ pub fn allow_comments_on_post(p: &Post) -> ResultBoxError<bool> {
|
||||
}
|
||||
|
||||
/// Set a new visibility level to a post
|
||||
pub fn set_level(post_id: u64, level: PostVisibilityLevel) -> ResultBoxError {
|
||||
pub fn set_level(post_id: u64, level: &PostVisibilityLevel) -> ResultBoxError {
|
||||
database::UpdateInfo::new(POSTS_TABLE)
|
||||
.cond_u64("ID", post_id)
|
||||
.set_u32("niveau_visibilite", level.to_db())
|
||||
|
Reference in New Issue
Block a user