mirror of
https://git.friendi.ca/friendica/friendica-addons.git
synced 2024-11-21 23:43:42 +00:00
Cleaned up code
This commit is contained in:
parent
981e6821d0
commit
0eda161e04
1 changed files with 1 additions and 8 deletions
|
@ -53,11 +53,6 @@ function cld_get_language(array &$data)
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($original == $detected) {
|
if ($original == $detected) {
|
||||||
// return;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Nur aus Testgründen
|
|
||||||
if (in_array($detected, ['xx-Qaai', 'ht', 'ga'])) {
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -68,8 +63,6 @@ function cld_get_language(array &$data)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
Logger::debug('Detected', ['original' => $original, 'detected' => $detected, 'name' => $result['language_name'], 'probability' => $result['language_probability'], 'text' => $data['text']]);
|
Logger::debug('Detected different language', ['original' => $original, 'detected' => $detected, 'name' => $result['language_name'], 'probability' => $result['language_probability'], 'text' => $data['text']]);
|
||||||
|
|
||||||
// Logger::debug('Detected different language', ['original' => $original, 'detected' => $detected, 'name' => $result['language_name'], 'probability' => $result['language_probability'], 'text' => $data['text']]);
|
|
||||||
$data['detected'] = [$detected => $result['language_probability'] / 100];
|
$data['detected'] = [$detected => $result['language_probability'] / 100];
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue