mirror of
https://github.com/M66B/FairEmail.git
synced 2026-04-18 23:13:36 +02:00
Allow standalone older than condition
This commit is contained in:
@@ -246,10 +246,11 @@ public class EntityRule {
|
||||
JSONObject jcondition = new JSONObject(condition);
|
||||
|
||||
// general
|
||||
int age = 0;
|
||||
if (this.daily) {
|
||||
JSONObject jgeneral = jcondition.optJSONObject("general");
|
||||
if (jgeneral != null) {
|
||||
int age = jgeneral.optInt("age");
|
||||
age = jgeneral.optInt("age");
|
||||
if (age > 0) {
|
||||
Calendar cal = Calendar.getInstance();
|
||||
cal.setTimeInMillis(message.received);
|
||||
@@ -505,7 +506,8 @@ public class EntityRule {
|
||||
}
|
||||
|
||||
// Safeguard
|
||||
if (jsender == null &&
|
||||
if (age == 0 &&
|
||||
jsender == null &&
|
||||
jrecipient == null &&
|
||||
jsubject == null &&
|
||||
!jcondition.optBoolean("attachments") &&
|
||||
|
||||
@@ -1686,7 +1686,15 @@ public class FragmentRule extends FragmentBase {
|
||||
}
|
||||
}
|
||||
|
||||
if (jsender == null &&
|
||||
int age = 0;
|
||||
if (daily) {
|
||||
JSONObject jgeneral = jcondition.optJSONObject("general");
|
||||
if (jgeneral != null)
|
||||
age = jgeneral.optInt("age");
|
||||
}
|
||||
|
||||
if (age == 0 &&
|
||||
jsender == null &&
|
||||
jrecipient == null &&
|
||||
jsubject == null &&
|
||||
!jcondition.optBoolean("attachments") &&
|
||||
|
||||
Reference in New Issue
Block a user