Fix badges not displaying when dash (-) in title (#308)
This commit is contained in:
parent
231c2a3a1e
commit
9e95b69c11
|
@ -182,7 +182,7 @@ def view(package):
|
||||||
@is_package_page
|
@is_package_page
|
||||||
def shield(package, type):
|
def shield(package, type):
|
||||||
if type == "title":
|
if type == "title":
|
||||||
url = "https://img.shields.io/badge/ContentDB-{}-{}" \
|
url = "https://img.shields.io/static/v1?label=ContentDB&message={}&color={}" \
|
||||||
.format(urlescape(package.title), urlescape("#375a7f"))
|
.format(urlescape(package.title), urlescape("#375a7f"))
|
||||||
elif type == "downloads":
|
elif type == "downloads":
|
||||||
#api_url = abs_url_for("api.package", author=package.author.username, name=package.name)
|
#api_url = abs_url_for("api.package", author=package.author.username, name=package.name)
|
||||||
|
|
Loading…
Reference in New Issue