bugfix - groups were emptied