From 47636f8b0afc3300c33ed860ee6f7d302ef6a61f Mon Sep 17 00:00:00 2001 From: tibbi Date: Tue, 23 Oct 2018 10:50:51 +0200 Subject: [PATCH] fix Favorite items getting removed at emptying the recycle bin --- .../com/simplemobiletools/gallery/interfaces/MediumDao.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/kotlin/com/simplemobiletools/gallery/interfaces/MediumDao.kt b/app/src/main/kotlin/com/simplemobiletools/gallery/interfaces/MediumDao.kt index ab8f76c48..5a02476b0 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/interfaces/MediumDao.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/interfaces/MediumDao.kt @@ -33,7 +33,7 @@ interface MediumDao { @Query("DELETE FROM media WHERE full_path = :path COLLATE NOCASE") fun deleteMediumPath(path: String) - @Query("DELETE FROM media WHERE deleted_ts < :timestmap") + @Query("DELETE FROM media WHERE deleted_ts < :timestmap AND deleted_ts != 0") fun deleteOldRecycleBinItems(timestmap: Long) @Query("UPDATE OR REPLACE media SET filename = :newFilename, full_path = :newFullPath, parent_path = :newParentPath WHERE full_path = :oldPath COLLATE NOCASE")