forked from zaclys/searxng
		
	
							parent
							
								
									e303339370
								
							
						
					
					
						commit
						f3aa5ea47d
					
				
					 1 changed files with 10 additions and 1 deletions
				
			
		|  | @ -74,8 +74,17 @@ def response(resp): | |||
|     for result in search_results[0].get('items', []): | ||||
|         # parse image results | ||||
|         if result.get('image'): | ||||
| 
 | ||||
|             result_url = '' | ||||
|             if 'url' in result: | ||||
|                 result_url = result['url'] | ||||
|             elif 'link' in result: | ||||
|                 result_url = result['link'] | ||||
|             else: | ||||
|                 continue | ||||
| 
 | ||||
|             # append result | ||||
|             results.append({'url': result['url'], | ||||
|             results.append({'url': result_url, | ||||
|                             'title': result['title'], | ||||
|                             'content': '', | ||||
|                             'img_src': result['image'], | ||||
|  |  | |||
		Loading…
	
	Add table
		
		Reference in a new issue
	
	 Noémi Ványi
						Noémi Ványi