Fixed wrong count for existing items on collection type

The children-call on the collection type returned 0, even if there were already items present. This lead to unexpected behavior if you had already existing items in a collection (overwrite of the first item if a  new item was inserted).