Some changes to event.js