bugfixes for issue 161 

and FIXME: also check that there is no object ID when type is singleton? --> done