def _get_vdis_for_instance(self, context, instance, name_label,
                               image_meta, image_type, block_device_info):
        """Create or connect to all virtual disks for this instance."""

        vdis = self._connect_cinder_volumes(instance, block_device_info)

        # If we didn't get a root VDI from volumes,
        # then use the Glance image as the root device
        if vdis not in 'root':
            create_image_vdis = vm_utils.create_image(context, self._session,
                    instance, name_label, image_meta.id, image_type)
            vdis.update(create_image_vdis)

        # Fetch VDI refs now so we don't have to fetch the ref multiple times
        for vdi in six.itervalues(vdis):
            vdi['ref'] = self._session.call_xenapi('VDI.get_by_uuid',
                                                   vdi['uuid'])
        return vdis
dataset/ETHPy150Open openstack/nova/nova/virt/xenapi/vmops.py/VMOps._get_vdis_for_instance/swapped operands of `not in`