mirror of
				https://github.com/searxng/searxng
				synced 2024-01-01 19:24:07 +01:00 
			
		
		
		
	Merge pull request #2238 from return42/fix-2027
[fix] fix threshold in replace_auto_language
This commit is contained in:
		
						commit
						94430e104c
					
				
					 1 changed files with 1 additions and 1 deletions
				
			
		| 
						 | 
				
			
			@ -54,7 +54,7 @@ def replace_auto_language(search_query: SearchQuery):
 | 
			
		|||
    if search_query.lang != 'auto':
 | 
			
		||||
        return
 | 
			
		||||
 | 
			
		||||
    detected_lang = detect_language(search_query.query, threshold=0.0, only_search_languages=True)
 | 
			
		||||
    detected_lang = detect_language(search_query.query, threshold=0.3, only_search_languages=True)
 | 
			
		||||
    if detected_lang is None:
 | 
			
		||||
        # fallback to 'all' if no language has been detected
 | 
			
		||||
        search_query.lang = 'all'
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		
		Reference in a new issue