diff --git a/ckan/templates/package/resources.html b/ckan/templates/package/resources.html
index 0e02b3846dd..dcb708e6d40 100644
--- a/ckan/templates/package/resources.html
+++ b/ckan/templates/package/resources.html
@@ -11,8 +11,9 @@
{% block primary_content_inner %}
{% if pkg.resources %}
+ {% set can_edit = h.check_access('package_update', {'id':pkg.id }) %}
{% for resource in pkg.resources %}
- {% snippet 'package/snippets/resource_item.html', pkg=pkg, res=resource, url_is_edit=true %}
+ {% snippet 'package/snippets/resource_item.html', pkg=pkg, res=resource, url_is_edit=true, can_edit=can_edit %}
{% endfor %}
{% else %}
diff --git a/ckan/templates/package/snippets/resource_item.html b/ckan/templates/package/snippets/resource_item.html
index e38f3e1d50f..8e437da6f7d 100644
--- a/ckan/templates/package/snippets/resource_item.html
+++ b/ckan/templates/package/snippets/resource_item.html
@@ -1,4 +1,3 @@
-{% set can_edit = h.check_access('package_update', {'id':pkg.id }) %}
{% set url_action = 'resource_edit' if url_is_edit and can_edit else 'resource_read' %}
{% set url = h.url_for(controller='package', action=url_action, id=pkg.name, resource_id=res.id) %}
diff --git a/ckan/templates/package/snippets/resources_list.html b/ckan/templates/package/snippets/resources_list.html
index 5fdd853a458..140df8fb627 100644
--- a/ckan/templates/package/snippets/resources_list.html
+++ b/ckan/templates/package/snippets/resources_list.html
@@ -15,8 +15,9 @@ {{ _('Data and Resources') }}
{% if resources %}
{% block resource_list_inner %}
+ {% set can_edit = h.check_access('package_update', {'id':pkg.id }) %}
{% for resource in resources %}
- {% snippet 'package/snippets/resource_item.html', pkg=pkg, res=resource %}
+ {% snippet 'package/snippets/resource_item.html', pkg=pkg, res=resource, can_edit=can_edit %}
{% endfor %}
{% endblock %}