Skip to content

Commit

Permalink
Only show login form if not using openid
Browse files Browse the repository at this point in the history
  • Loading branch information
timonegk committed Jan 12, 2024
1 parent fa32c9d commit 8b6a9e6
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion bitpoll/base/templates/base/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,8 @@ <h1>{% trans 'Create a poll' %}</h1>
</div>
</div>
</section>
{% if request.user.is_anonymous %}
{% value_from_settings OPENID_ENABLED as openid %}
{% if request.user.is_anonymous and not openid %}
<section class="section login">
<div class="container">
<div class="halfsize">
Expand Down
1 change: 1 addition & 0 deletions bitpoll/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@
'POLL_CREATION_REQUIRES_LOGIN',
'POLL_CREATION_ACCOUNT_WEBSITE',
'POLL_CREATION_ACCOUNT_NAME',
'OPENID_ENABLED',
]

LOGIN_REDIRECT_URL = "/"
Expand Down

0 comments on commit 8b6a9e6

Please sign in to comment.