@@ -42,7 +42,8 @@ from searx.engines import (
43from searx.utils import (
43from searx.utils import (
44 UnicodeWriter, highlight_content, html_to_text, get_themes,
44 UnicodeWriter, highlight_content, html_to_text, get_themes,
45− get_static_files, get_result_templates, gen_useragent, dict_subset
45+ get_static_files, get_result_templates, gen_useragent, dict_subset,
47from searx.version import VERSION_STRING
48from searx.version import VERSION_STRING
48from searx.languages import language_codes
49from searx.languages import language_codes
@@ -330,11 +331,7 @@ def index():
330 result['title'] = ' '.join(html_to_text(result['title'])
331 result['title'] = ' '.join(html_to_text(result['title'])
331 .strip().split())
332 .strip().split())
333− if len(result['url']) > 74:
334+ result['pretty_url'] = prettify_url(result['url'])
334− url_parts = result['url'][:35], result['url'][-35:]
335− result['pretty_url'] = u'{0}[...]{1}'.format(*url_parts)
337− result['pretty_url'] = result['url']
339 # TODO, check if timezone is calculated right
336 # TODO, check if timezone is calculated right
340 if 'publishedDate' in result:
337 if 'publishedDate' in result: