You are here

function biblio_delete_contributors in Bibliography Module 6.2

Same name and namespace in other branches
  1. 6 biblio.contributors.inc \biblio_delete_contributors()
  2. 7 includes/biblio.contributors.inc \biblio_delete_contributors()
  3. 7.2 includes/biblio.contributors.inc \biblio_delete_contributors()

Deletes all contributors associated with node ID.

// @todo: Refactor to take a node ID or a node object? // @todo: Shouldn't this return success?

Parameters

object $node: A node object that contains a property 'nid'.

Return value

null ? change to $success?

2 calls to biblio_delete_contributors()
BiblioContributorUnitTest::testBiblioUpdateContributors in tests/contributor.test
biblio_delete in ./biblio.module
Implements hook_delete().

File

includes/biblio.contributors.inc, line 194
Functions related to contributors in Drupal biblio module.

Code

function biblio_delete_contributors($node) {
  db_query('DELETE FROM {biblio_contributor} WHERE nid = %d', array(
    ':nid' => $node->nid,
  ));
  return;
}