diff --git a/app/src/main/java/gallery/memories/service/TimelineQuery.java b/app/src/main/java/gallery/memories/service/TimelineQuery.java index fbf09975..5827d6dc 100644 --- a/app/src/main/java/gallery/memories/service/TimelineQuery.java +++ b/app/src/main/java/gallery/memories/service/TimelineQuery.java @@ -293,7 +293,6 @@ public class TimelineQuery { } // Delete file with media store - Uri collection = MediaStore.Images.Media.EXTERNAL_CONTENT_URI; if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.R) { PendingIntent intent = MediaStore.createTrashRequest(mCtx.getContentResolver(), uris, true); deleteIntentLauncher.launch(new IntentSenderRequest.Builder(intent.getIntentSender()).build()); @@ -313,6 +312,9 @@ public class TimelineQuery { } } + // Delete from images table + mDb.execSQL("DELETE FROM images WHERE local_id IN (" + TextUtils.join(",", ids) + ")"); + return new JSONObject().put("message", "ok"); } finally { synchronized (this) {