Move the login form context out of the profiles app
This commit is contained in:
@@ -1,7 +1,11 @@
|
||||
import models
|
||||
from django.contrib.auth.forms import AuthenticationForm
|
||||
|
||||
def random_quote(request):
|
||||
quote = models.Quote.objects.order_by('?')
|
||||
if len(quote) > 0:
|
||||
return {'quote': quote[0]}
|
||||
return {}
|
||||
|
||||
def login_form(request):
|
||||
return {'login_form': AuthenticationForm()}
|
||||
|
@@ -1,3 +0,0 @@
|
||||
from django.contrib.auth.forms import AuthenticationForm
|
||||
def login_form(request):
|
||||
return {'login_form': AuthenticationForm()}
|
@@ -168,7 +168,7 @@ TEMPLATE_CONTEXT_PROCESSORS = (
|
||||
"django.core.context_processors.static",
|
||||
"django.contrib.messages.context_processors.messages",
|
||||
"local.context.random_quote",
|
||||
"profiles.context.login_form",
|
||||
"local.context.login_form",
|
||||
"minecraft.context.server_info",
|
||||
"appversion.context.git_version"
|
||||
)
|
||||
|
Reference in New Issue
Block a user