1.20.x node.install node_update_1015()

Add column for scheduling the publishing of content in the future.

Related topics

File

modules/node/node.install, line 1154
Install, update and uninstall functions for the node module.

Code

function node_update_1015() {
  if (db_field_exists('node', 'scheduled')) {
    return;
  }

  $spec = array(
    'description' => 'A Unix timestamp indicating content is scheduled to be published in the future.',
    'type' => 'int',
    'not null' => TRUE,
    'default' => 0,
  );
  db_add_field('node', 'scheduled', $spec);
}