Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

odd design: context_processors.backend_data #245

Closed
derks opened this issue Feb 9, 2012 · 0 comments
Closed

odd design: context_processors.backend_data #245

derks opened this issue Feb 9, 2012 · 0 comments

Comments

@derks
Copy link

derks commented Feb 9, 2012

In context_processors.backend_data() ... the 'values' returned are inconsistent with eachother. The 'associated' key contains a list of UserSocialAuth association objects... where 'not_associated' contains a list of provider objects. This makes an odd use case:

{% for provider in social_auth.associated.all %}
    Provider is: {{ provider.provider }} (actually association.provider)
{% endfor %}

{% for provider in social_auth.not_associated.all %}
    Provider is: {{ provider }} (actually is the provider)
{% endfor %}

If anything, would be helpful to document context processors a bit better. Currently the only mention to the context_processors is in the configuration doc:

Define context processors if needed:

 TEMPLATE_CONTEXT_PROCESSORS = (
     ...
     'social_auth.context_processors.social_auth_by_type_backends',
 )

check `social_auth.context_processors`.

Where the 'link' at the bottom doesn't link to anything.

@omab omab closed this as completed in bec39d7 Feb 9, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants