Skip to content
Snippets Groups Projects
Commit e7d04b9d authored by Dave Reid's avatar Dave Reid
Browse files

Issue #1191494 by twistor, Dave Reid: Fixed link to node type feed importer...

Issue #1191494 by twistor, Dave Reid: Fixed link to node type feed importer did not use node_access().
parent 79a2ddff
No related branches found
No related tags found
No related merge requests found
...@@ -22,10 +22,13 @@ function feeds_page() { ...@@ -22,10 +22,13 @@ function feeds_page() {
$link = 'import/' . $importer->id; $link = 'import/' . $importer->id;
$title = $importer->config['name']; $title = $importer->config['name'];
} }
elseif (user_access('create ' . $importer->config['content_type'] . ' content')) { elseif (node_access('create', $importer->config['content_type'])) {
$link = 'node/add/' . str_replace('_', '-', $importer->config['content_type']); $link = 'node/add/' . str_replace('_', '-', $importer->config['content_type']);
$title = node_type_get_name($importer->config['content_type']); $title = node_type_get_name($importer->config['content_type']);
} }
else {
continue;
}
$rows[] = array( $rows[] = array(
l($title, $link), l($title, $link),
check_plain($importer->config['description']), check_plain($importer->config['description']),
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment