avoid ConcurrentModificationException
This commit is contained in:
parent
68faba8951
commit
3f561943dc
|
@ -193,7 +193,9 @@ class AutomationPlugin @Inject constructor(
|
|||
}
|
||||
|
||||
aapsLogger.debug(LTag.AUTOMATION, "processActions")
|
||||
for (event in automationEvents) {
|
||||
val iterator = automationEvents.iterator()
|
||||
while (iterator.hasNext()) {
|
||||
val event = iterator.next()
|
||||
if (event.isEnabled && event.shouldRun() && event.trigger.shouldRun() && event.getPreconditions().shouldRun()) {
|
||||
if (event.systemAction || userEventsEnabled) {
|
||||
val actions = event.actions
|
||||
|
|
Loading…
Reference in a new issue