summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorDavid Rothstein <drothstein@gmail.com>2015-03-30 19:03:15 -0400
committerDavid Rothstein <drothstein@gmail.com>2015-03-30 19:03:15 -0400
commite8a38c6175619fea2e3b1bbcc39c6a4cf35af5d6 (patch)
tree12fe919840caa89ce91e4d8e46d8e64e49e4f120 /modules
parent517f137d4aa1e3681f46a4767ef0e5bcefa7ea40 (diff)
downloadbrdo-e8a38c6175619fea2e3b1bbcc39c6a4cf35af5d6.tar.gz
brdo-e8a38c6175619fea2e3b1bbcc39c6a4cf35af5d6.tar.bz2
Issue #2283717 by joshi.rohit100, amitgoyal, g3r4, er.pushpinderrana: Remove user_access function calls on hook_permission functions so the Permissions page consistently links to other admin pages for all users
Diffstat (limited to 'modules')
-rw-r--r--modules/filter/filter.module4
-rw-r--r--modules/node/node.module4
2 files changed, 2 insertions, 6 deletions
diff --git a/modules/filter/filter.module b/modules/filter/filter.module
index 5c2b8c97f..74621f108 100644
--- a/modules/filter/filter.module
+++ b/modules/filter/filter.module
@@ -348,9 +348,7 @@ function filter_permission() {
foreach (filter_formats() as $format) {
$permission = filter_permission_name($format);
if (!empty($permission)) {
- // Only link to the text format configuration page if the user who is
- // viewing this will have access to that page.
- $format_name_replacement = user_access('administer filters') ? l($format->name, 'admin/config/content/formats/' . $format->format) : drupal_placeholder($format->name);
+ $format_name_replacement = l($format->name, 'admin/config/content/formats/' . $format->format);
$perms[$permission] = array(
'title' => t("Use the !text_format text format", array('!text_format' => $format_name_replacement,)),
'description' => drupal_placeholder(t('Warning: This permission may have security implications depending on how the text format is configured.')),
diff --git a/modules/node/node.module b/modules/node/node.module
index ebac07902..a9c1d23e8 100644
--- a/modules/node/node.module
+++ b/modules/node/node.module
@@ -1578,9 +1578,7 @@ function node_permission() {
),
'access content overview' => array(
'title' => t('Access the content overview page'),
- 'description' => user_access('access content overview')
- ? t('Get an overview of <a href="@url">all content</a>.', array('@url' => url('admin/content')))
- : t('Get an overview of all content.'),
+ 'description' => t('Get an overview of <a href="@url">all content</a>.', array('@url' => url('admin/content'))),
),
'access content' => array(
'title' => t('View published content'),