RAZ-2209: Security for custom fields did not work properly when more then one group was allocated