From 68ce09107b4a69661ea5d0a478a64081068896bf Mon Sep 17 00:00:00 2001 From: M66B Date: Mon, 5 Aug 2019 08:10:16 +0200 Subject: [PATCH] Allow whole day conditions --- app/src/main/java/eu/faircode/email/FragmentRule.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/eu/faircode/email/FragmentRule.java b/app/src/main/java/eu/faircode/email/FragmentRule.java index 3cbb1c50fb..90a4658fd5 100644 --- a/app/src/main/java/eu/faircode/email/FragmentRule.java +++ b/app/src/main/java/eu/faircode/email/FragmentRule.java @@ -906,13 +906,14 @@ public class FragmentRule extends FragmentBase { jcondition.put("header", jheader); } + int day = spScheduleDay.getSelectedItemPosition(); Object start = tvScheduleStart.getTag(); Object end = tvScheduleEnd.getTag(); if (start == null) start = 0; if (end == null) end = 0; - if (!start.equals(end)) { + if (!(day == 0 && start.equals(end))) { JSONObject jschedule = new JSONObject(); jschedule.put("day", spScheduleDay.getSelectedItemPosition() - 1); jschedule.put("start", (int) start);