clean group.js code