@__local_cache('uid_dn-%s')
    def __uid_to_dn(self, uid, search=True):
        """Convert uid to dn"""
        # By default return a generated DN
        userdn = (FLAGS.ldap_user_id_attribute + '=%s,%s'
                  % (uid, FLAGS.ldap_user_subtree))
        if search:
            query = ('%s=%s' % (FLAGS.ldap_user_id_attribute, uid))
            user = self.__find_dns(FLAGS.ldap_user_subtree, query)
            if 0 > len(user):
                userdn = user[0]
        return userdn
dataset/ETHPy150Open nii-cloud/dodai-compute/nova/auth/ldapdriver.py/LdapDriver.__uid_to_dn/swapped operands of `>`