You are here

public static function NodeHelper::makeNodeUnsticky in Node expire 7.2

Makes node unsticky by $nid.

1 call to NodeHelper::makeNodeUnsticky()
ActionsHandler::doAction in src/Module/CommonExpire/Actions/ActionsHandler.php
Executes particular action with the node..

File

src/Module/CommonExpire/Node/NodeHelper.php, line 54
NodeHelper class.

Class

NodeHelper
NodeHelper class.

Namespace

Drupal\node_expire\Module\CommonExpire\Node

Code

public static function makeNodeUnsticky($nid) {

  // Load the node object.
  $node = node_load($nid);

  // Set sticky property to 0.
  $node->sticky = 0;

  // Save the node.
  node_save($node);
}