Fixed jQuery .on event handler