Fix language detection of non-latin alphabets even at few characters (#10276)
This commit is contained in:
parent
ba84b6d4d7
commit
1b167707c2
2 changed files with 26 additions and 9 deletions
|
@ -106,11 +106,11 @@ describe LanguageDetector do
|
|||
end
|
||||
|
||||
describe 'remote user' do
|
||||
it 'nil for foreign user when language is not present' do
|
||||
it 'detects Korean language' do
|
||||
string = '안녕하세요'
|
||||
result = described_class.instance.detect(string, account_remote)
|
||||
|
||||
expect(result).to eq nil
|
||||
expect(result).to eq :ko
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue