mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-22 06:30:59 +01:00
Use duplicate threshold preference instead of constant 2 for edit dialog duplication check
This commit is contained in:
parent
f6c8256500
commit
07faccfa37
@ -2599,6 +2599,7 @@ window.egw_LAB.wait(function() {
|
||||
{
|
||||
$matches = null;
|
||||
$fields = explode(',',$GLOBALS['egw_info']['user']['preferences']['addressbook']['duplicate_fields']);
|
||||
$threshold = (int)$GLOBALS['egw_info']['user']['preferences']['addressbook']['duplicate_threshold'];
|
||||
|
||||
if (preg_match('/^exec\[([^\]]+)\]$/', $name, $matches)) $name = $matches[1]; // remove exec[ ]
|
||||
|
||||
@ -2631,7 +2632,7 @@ window.egw_LAB.wait(function() {
|
||||
$specified_count++;
|
||||
}
|
||||
}
|
||||
if (in_array($name,$fields) && $specified_count >= 2)
|
||||
if (in_array($name,$fields) && $specified_count >= $threshold)
|
||||
{
|
||||
$filter = array();
|
||||
foreach($fields as $n) // use email too, to exclude obvious false positives
|
||||
|
Loading…
Reference in New Issue
Block a user