mirror of
https://github.com/aljazceru/CTFd.git
synced 2025-12-17 22:14:25 +01:00
Use authed function to check if user is authed in base.html (#1283)
* Use `authed` function to check if user is authed in `base.html`
This commit is contained in:
@@ -81,7 +81,7 @@
|
||||
<hr class="d-sm-flex d-md-flex d-lg-none">
|
||||
|
||||
<ul class="navbar-nav ml-md-auto d-block d-sm-flex d-md-flex">
|
||||
{% if name is defined %}
|
||||
{% if authed() %}
|
||||
{% if type == 'admin' %}
|
||||
<li class="nav-item">
|
||||
<a class="nav-link" href="{{ url_for('admin.view') }}">
|
||||
|
||||
@@ -74,6 +74,7 @@ def init_template_globals(app):
|
||||
app.jinja_env.globals.update(scores_visible=scores_visible)
|
||||
app.jinja_env.globals.update(get_mode_as_word=get_mode_as_word)
|
||||
app.jinja_env.globals.update(integrations=integrations)
|
||||
app.jinja_env.globals.update(authed=authed)
|
||||
|
||||
|
||||
def init_logs(app):
|
||||
|
||||
Reference in New Issue
Block a user