You are here

function node_expire_unset_expired in Node expire 7.2

Same name and namespace in other branches
  1. 8 node_expire.rules.inc \node_expire_unset_expired()
  2. 6.2 node_expire.rules.inc \node_expire_unset_expired()
  3. 7 node_expire.rules.inc \node_expire_unset_expired()

Unsets the "Expired" flag on nodes.

Parameters

object $node: The Node object with all node IDs that should unset the expired flag.

File

./node_expire.rules.inc, line 80
Rules module integration.

Code

function node_expire_unset_expired($node) {
  $wrapper = entity_metadata_wrapper('node', $node);
  $value = $wrapper
    ->value();
  $value->expired = 0;
  $value->lastnotify = 0;
  $wrapper
    ->set($value);
  $wrapper
    ->save();
}