add code to groups