def get_config(context):
    """
    Return the formatted javascript for any disqus config variables.
    """

    conf_vars = ['disqus_developer',
                 'disqus_identifier',
                 'disqus_url',
                 'disqus_title',
                 'disqus_category_id'
                 ]

    js = '\tvar {} = "{}";'

    output = [js.format(item, context[item]) for item in conf_vars \
              if item in context]

    return '\n'.join(output)
dataset/ETHPy150Open arthurk/django-disqus/disqus/templatetags/disqus_tags.py/get_config/original