From f1bf5ccdd89658cb50ae04368f71ccbf4d5a6ac3 Mon Sep 17 00:00:00 2001 From: Devan Goodwin Date: Sun, 20 Oct 2013 17:06:56 -0300 Subject: [PATCH] Fix error in collection templates. Removed unicode strings from some recently added has_privilege calls. Appears this is not valid syntax as it would be in the python code itself. Causes an error showing the template: Error - : expected token ',', got 'string' --- .../templates/mediagoblin/user_pages/collection.html | 12 ++++++------ .../mediagoblin/utils/collection_gallery.html | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/mediagoblin/templates/mediagoblin/user_pages/collection.html b/mediagoblin/templates/mediagoblin/user_pages/collection.html index 87635dcb..988c6556 100644 --- a/mediagoblin/templates/mediagoblin/user_pages/collection.html +++ b/mediagoblin/templates/mediagoblin/user_pages/collection.html @@ -44,8 +44,8 @@ {{ collection_title }} by {{ username }} {%- endtrans %} - {% if request.user and (collection.creator == request.user.id or - request.user.has_privilege(u'admin')) %} + {% if request.user and (collection.creator == request.user.id or + request.user.ghas_privilege('admin')) %} {% set edit_url = request.urlgen('mediagoblin.edit.edit_collection', user=collection.get_creator.username, collection=collection.slug) %} @@ -63,10 +63,10 @@

{{ collection_gallery(request, collection_items, pagination) }} - + {% set feed_url = request.urlgen('mediagoblin.user_pages.collection_atom_feed', - user=user.username, + user=user.username, collection=collection.slug ) %} {% include "mediagoblin/utils/feed_link.html" %} - -{% endblock %} + +{% endblock %} diff --git a/mediagoblin/templates/mediagoblin/utils/collection_gallery.html b/mediagoblin/templates/mediagoblin/utils/collection_gallery.html index 24bf6832..dfe2ebe2 100644 --- a/mediagoblin/templates/mediagoblin/utils/collection_gallery.html +++ b/mediagoblin/templates/mediagoblin/utils/collection_gallery.html @@ -38,8 +38,8 @@ {{ item.note }} {% endif %} {% if request.user and - (item.in_collection.creator == request.user.id or - request.user.has_privilege(u'admin')) %} + (item.in_collection.creator == request.user.id or + request.user.has_privilege('admin')) %} {%- set remove_url=request.urlgen( 'mediagoblin.user_pages.collection_item_confirm_remove', user=item.in_collection.get_creator.username, -- 2.25.1