added functionality to trigger