|  | @@ -2,7 +2,7 @@
 | 
	
		
			
			| 2 | 2 |  
 | 
	
		
			
			| 3 | 3 |  """
 | 
	
		
			
			| 4 | 4 |   ArXiV (Scientific preprints)
 | 
	
		
			
			| 5 |  | - @website     https://axiv.org
 | 
	
		
			
			|  | 5 | + @website     https://arxiv.org
 | 
	
		
			
			| 6 | 6 |   @provide-api yes (export.arxiv.org/api/query)
 | 
	
		
			
			| 7 | 7 |   @using-api   yes
 | 
	
		
			
			| 8 | 8 |   @results     XML-RSS
 | 
	
	
		
			
			|  | @@ -41,7 +41,8 @@ def request(query, params):
 | 
	
		
			
			| 41 | 41 |  def response(resp):
 | 
	
		
			
			| 42 | 42 |      results = []
 | 
	
		
			
			| 43 | 43 |  
 | 
	
		
			
			| 44 |  | -    search_results = html.fromstring(resp.text).xpath('//entry')
 | 
	
		
			
			|  | 44 | +    dom = html.fromstring(resp.content)
 | 
	
		
			
			|  | 45 | +    search_results = dom.xpath('//entry')
 | 
	
		
			
			| 45 | 46 |  
 | 
	
		
			
			| 46 | 47 |      for entry in search_results:
 | 
	
		
			
			| 47 | 48 |          title = entry.xpath('.//title')[0].text
 | 
	
	
		
			
			|  | @@ -49,15 +50,15 @@ def response(resp):
 | 
	
		
			
			| 49 | 50 |          url = entry.xpath('.//id')[0].text
 | 
	
		
			
			| 50 | 51 |  
 | 
	
		
			
			| 51 | 52 |          content_string = '{doi_content}{abstract_content}'
 | 
	
		
			
			| 52 |  | -       
 | 
	
		
			
			|  | 53 | +
 | 
	
		
			
			| 53 | 54 |          abstract = entry.xpath('.//summary')[0].text
 | 
	
		
			
			| 54 | 55 |  
 | 
	
		
			
			| 55 | 56 |          #  If a doi is available, add it to the snipppet
 | 
	
		
			
			| 56 | 57 |          try:
 | 
	
		
			
			| 57 | 58 |              doi_content = entry.xpath('.//link[@title="doi"]')[0].text
 | 
	
		
			
			| 58 |  | -            content = content_string.format(doi_content=doi_content, abstract_content=abstract_content)
 | 
	
		
			
			|  | 59 | +            content = content_string.format(doi_content=doi_content, abstract_content=abstract)
 | 
	
		
			
			| 59 | 60 |          except:
 | 
	
		
			
			| 60 |  | -            content = content_string.format(abstract_content=abstract_content)
 | 
	
		
			
			|  | 61 | +            content = content_string.format(doi_content="", abstract_content=abstract)
 | 
	
		
			
			| 61 | 62 |  
 | 
	
		
			
			| 62 | 63 |          if len(content) > 300:
 | 
	
		
			
			| 63 | 64 |                      content = content[0:300] + "..."
 |