ZIP import / export now include inbox content
This commit is contained in:
@@ -111,3 +111,11 @@ pub async fn delete(id: InboxEntryID) -> anyhow::Result<()> {
|
||||
diesel::delete(inbox::dsl::inbox.filter(inbox::dsl::id.eq(id.0))).execute(&mut db()?)?;
|
||||
Ok(())
|
||||
}
|
||||
|
||||
/// Delete all the inbox entries of a user
|
||||
pub async fn delete_all_user(user: UserID) -> anyhow::Result<()> {
|
||||
for inbox_entry in get_list_user(user).await? {
|
||||
delete(inbox_entry.id()).await?;
|
||||
}
|
||||
Ok(())
|
||||
}
|
||||
|
Reference in New Issue
Block a user