fixed bug with triggering