$_object_mode
$_object_mode :
Helper to merge duplicate objects
$config : \midcom_helper_configuration
__construct(string $mode, \midcom_helper_configuration $config)
Constructor, the parameter governs which objects the instance works on
string | $mode | currently valid modes are 'person' and 'group' |
\midcom_helper_configuration | $config |
merge_delete(\midcom_core_dbaobject $obj1, \midcom_core_dbaobject $obj2)
Merges first object with second and then deletes the second
\midcom_core_dbaobject | $obj1 | Object that will remain |
\midcom_core_dbaobject | $obj2 | Object that will be deleted |
merge_needed() : boolean
Checks if there are any objects (for the mode given in constructor) that need to be processed
Note: does not check user's privileges or that the objects actually exist (the cleanup cronjob handles dangling references)
indicating need for processing (merge/not duplicate)
check_duplicate(array $results, \midcom_core_dbaobject $object, $field)
array | $results | |
\midcom_core_dbaobject | $object | |
$field |