mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-09-15 15:32:30 +03:00
Fix external link formatting
This commit is contained in:
parent
be50d2db4a
commit
ca341bb170
1 changed files with 2 additions and 2 deletions
|
@ -704,13 +704,13 @@ class DescriptionFormatter:
|
||||||
index = txt.find("]")
|
index = txt.find("]")
|
||||||
if index == -1:
|
if index == -1:
|
||||||
raise MetaDataException("Unterminated ]")
|
raise MetaDataException("Unterminated ]")
|
||||||
url = txt[2:index]
|
url = txt[1:index]
|
||||||
index2 = url.find(' ')
|
index2 = url.find(' ')
|
||||||
if index2 == -1:
|
if index2 == -1:
|
||||||
urltxt = url
|
urltxt = url
|
||||||
else:
|
else:
|
||||||
urltxt = url[index2 + 1:]
|
urltxt = url[index2 + 1:]
|
||||||
url = url[:index]
|
url = url[:index2]
|
||||||
linkified_html += '<a href="' + url + '">' + cgi.escape(urltxt) + '</a>'
|
linkified_html += '<a href="' + url + '">' + cgi.escape(urltxt) + '</a>'
|
||||||
linkified_plain += urltxt
|
linkified_plain += urltxt
|
||||||
if urltxt != url:
|
if urltxt != url:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue