added snippet looking for events