Skip to content
Snippets Groups Projects
Commit 0b9b38a4 authored by Daniele Piaggesi's avatar Daniele Piaggesi
Browse files

_prevnext_get_prevnext now does not extract unpublished contents

parent aff81069
No related branches found
No related tags found
No related merge requests found
......@@ -130,7 +130,8 @@ function prevnext_field_extra_fields() {
function _prevnext_get_prevnext($node, $language = NULL) {
$query = new EntityFieldQuery();
$query->entityCondition('entity_type', 'node')
->propertyCondition('type', $node->type);
->propertyCondition('type', $node->type)
->propertyCondition('status', 1);
if (!is_null($language)) {
$query->propertyCondition('language', $language);
......
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