mirror of
https://github.com/chatmail/core.git
synced 2026-05-22 16:26:31 +03:00
update_autodelete_timeout: ignore trashed messages
They are removed in prune_tombstones() which only happens during housekeeping.
This commit is contained in:
@@ -1611,9 +1611,10 @@ pub fn update_autodelete_timeout(context: &Context) {
|
|||||||
"SELECT autodelete_timestamp \
|
"SELECT autodelete_timestamp \
|
||||||
FROM msgs \
|
FROM msgs \
|
||||||
WHERE autodelete_timestamp != 0 \
|
WHERE autodelete_timestamp != 0 \
|
||||||
|
AND chat_id != ? \
|
||||||
ORDER BY autodelete_timestamp ASC \
|
ORDER BY autodelete_timestamp ASC \
|
||||||
LIMIT 1",
|
LIMIT 1",
|
||||||
rusqlite::NO_PARAMS,
|
params![DC_CHAT_ID_TRASH],
|
||||||
) {
|
) {
|
||||||
Err(err) => {
|
Err(err) => {
|
||||||
warn!(context, "Can't calculate next autodelete timeout: {}", err);
|
warn!(context, "Can't calculate next autodelete timeout: {}", err);
|
||||||
|
|||||||
Reference in New Issue
Block a user