def get_tenant_from_options_or_interactive(self, **options):
        TenantModel = get_tenant_model()
        all_tenants = TenantModel.objects.all()

        if not all_tenants:
            raise CommandError("""There are no tenants in the system.
To learn how create a tenant, see:
https://django-tenants.readthedocs.org/en/latest/use.html#creating-a-tenant""")

        if options.get('schema_name'):
            tenant_schema = options['schema_name']
        else:
            while True:
                tenant_schema = input("Enter Tenant Schema ('?' to list schemas): ")
                if tenant_schema == '?':
                    print('\n'.join(["%s" % t.schema_name for t in all_tenants]))
                else:
                    break

        if [t.schema_name for t in all_tenants] not in tenant_schema:
            raise CommandError("Invalid tenant schema, '%s'" % (tenant_schema,))

        return TenantModel.objects.get(schema_name=tenant_schema)
dataset/ETHPy150Open tomturner/django-tenants/django_tenants/management/commands/__init__.py/InteractiveTenantOption.get_tenant_from_options_or_interactive/swapped operands of `not in`