Merge pull request #4728 from metalbear-co/aviram/fix-monitor-opt-in-loop