##// END OF EJS Templates
Updated context processor to work with a request without user defined (fixes...
neko259 -
r813:259d2595 default
parent child Browse files
Show More
@@ -30,7 +30,10 b' def user_and_ui_processor(request):'
30 context[CONTEXT_THEME_CSS] = 'css/' + theme + '/base_page.css'
30 context[CONTEXT_THEME_CSS] = 'css/' + theme + '/base_page.css'
31
31
32 # This shows the moderator panel
32 # This shows the moderator panel
33 moderate = request.user.has_perm('moderation')
33 try:
34 moderate = request.user.has_perm('moderation')
35 except AttributeError:
36 moderate = False
34 context[CONTEXT_MODERATOR] = moderate
37 context[CONTEXT_MODERATOR] = moderate
35
38
36 context[CONTEXT_VERSION] = settings.VERSION
39 context[CONTEXT_VERSION] = settings.VERSION
General Comments 0
You need to be logged in to leave comments. Login now