Fixes invisible items not being associated with the correct type when going through SolrDatabase with saveData set to false.