KAZOOUI-7: Fixed bug on ordering of groups (removing agent didn't work properly)