change overlapping "forEach" in Pattern to onOnset