def _get_config_settings(self, is_add=True):
    sso_config_key = ('sso_saml2_config%d' % self._config_index)
    sso_enabled_key = ('sso_saml2_enabled%d' % self._config_index)
    if is_add:
        sso_config_settings = self._metadata.get_values_as_dict()
        sso_config_settings['display_name'] = self._display_name
    else:
        sso_config_settings = {}
    return {sso_enabled_key: is_add, sso_config_key: dumps(sso_config_settings)}
def _get_config_settings(self, is_add=True):
    sso_config_key = ('sso_saml2_config%d' % self._config_index)
    sso_enabled_key = ('sso_saml2_enabled%d' % self._config_index)
    if is_add:
        sso_config_settings = self._metadata.get_values_as_dict()
        sso_config_settings['display_name'] = self._display_name
    else:
        sso_config_settings = {}
    return {sso_enabled_key: is_add, sso_config_key: dumps(sso_config_settings)}