You are here

function party_merge in Party 7

Same name and namespace in other branches
  1. 8.2 party.module \party_merge()

Merge two parties.

Parameters

$first the first party.:

$second the second party:

Deprecated

Use entity_merge() instead.

When running this function, the first party gets all of the second party's attached entities and the second party becomes a 'ghost' party that points to the first.

1 call to party_merge()
party_party_operations_merge in ./party.module
Merge multiple parties.

File

./party.module, line 1293
Provides a generic CRM party entity.

Code

function party_merge($first, $second) {
  trigger_error(__FUNCTION__ . " is deprecated. Use entity_merge() instead.", E_USER_DEPRECATED);
  if (!module_exists('entity_merge')) {
    watchdog('party', 'Entity Merge module is required to use party_merge().', array(), WATCHDOG_ERROR);
  }
  return entity_merge($first, $second, 'party');
}