JS cleanup events.js