add end event