More JS groups management. Should finally fix #376 ;)