Adding run listener functionality