Add updating events function