Skip to content

Commit

Permalink
Move variable substitution to template so the base for edition has or…
Browse files Browse the repository at this point in the history
…iginal variables not their values
  • Loading branch information
krassowski committed Jun 29, 2017
1 parent c64afcb commit cc674fc
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion website/templates/text_entry.html
Expand Up @@ -8,7 +8,7 @@
</div>
{% endif %}

<div class="content">{{ text_entry(id) | safe }}</div>
<div class="content">{{ text_entry(id) | safe | substitute_allowed_variables | safe }}</div>

{% if current_user.is_admin %}
<div class="alert alert-warning feedback" role="alert"></div>
Expand Down
2 changes: 1 addition & 1 deletion website/views/cms.py
Expand Up @@ -176,7 +176,7 @@ def _text_entry(name):
if current_user.is_admin:
return 'Please, click the pencil icon to add text here.'
return ''
return substitute_variables(entry.content)
return entry.content

@route('/admin/save_text_entry/', methods=['POST'])
@admin_only
Expand Down

0 comments on commit cc674fc

Please sign in to comment.