fix bug that groupObject removed all elements