Browse Source

Reset search

main
M66B 6 years ago
parent
commit
bf310662c1
2 changed files with 4 additions and 3 deletions
  1. +1
    -0
      app/src/main/java/eu/faircode/email/BoundaryCallbackMessages.java
  2. +3
    -3
      app/src/main/java/eu/faircode/email/DaoMessage.java

+ 1
- 0
app/src/main/java/eu/faircode/email/BoundaryCallbackMessages.java View File

@ -91,6 +91,7 @@ public class BoundaryCallbackMessages extends PagedList.BoundaryCallback<TupleMe
@Override @Override
public void run() { public void run() {
Log.i(Helper.TAG, "Boundary close"); Log.i(Helper.TAG, "Boundary close");
DB.getInstance(context).message().deleteFoundMessages();
try { try {
if (istore != null) if (istore != null)
istore.close(); istore.close();


+ 3
- 3
app/src/main/java/eu/faircode/email/DaoMessage.java View File

@ -224,9 +224,6 @@ public interface DaoMessage {
@Query("UPDATE message SET headers = :headers WHERE id = :id") @Query("UPDATE message SET headers = :headers WHERE id = :id")
int setMessageHeaders(long id, String headers); int setMessageHeaders(long id, String headers);
@Query("UPDATE message SET avatar = :avatar WHERE id = :id")
int setMessageAvatar(long id, String avatar);
@Query("DELETE FROM message WHERE id = :id") @Query("DELETE FROM message WHERE id = :id")
int deleteMessage(long id); int deleteMessage(long id);
@ -241,4 +238,7 @@ public interface DaoMessage {
@Query("DELETE FROM message WHERE folder = :folder AND received < :received AND NOT uid IS NULL") @Query("DELETE FROM message WHERE folder = :folder AND received < :received AND NOT uid IS NULL")
int deleteMessagesBefore(long folder, long received); int deleteMessagesBefore(long folder, long received);
@Query("DELETE FROM message WHERE ui_found")
int deleteFoundMessages();
} }

Loading…
Cancel
Save