Skip to content
Snippets Groups Projects
Verified Commit 14b33a64 authored by Pinguin's avatar Pinguin :penguin: Committed by Jonathan Weth
Browse files

Do tox lint and reformat

parent 42d515a2
No related branches found
No related tags found
3 merge requests!1237Release 3.0,!1233Resolve "Links in object column of data check table is broken",!1183Release 3.0
Pipeline #125875 failed
import random
import string
from urllib.parse import urlparse
from django import template
......@@ -32,7 +31,7 @@ def add_class_to_el(value: str, arg: str) -> str:
@register.filter
def remove_prefix(value: str, prefix: str) -> str:
"""Remove prefix of a url
"""Remove prefix of a url.
:Example:
......@@ -43,7 +42,7 @@ def remove_prefix(value: str, prefix: str) -> str:
url = urlparse(value)
if url.path.startswith(prefix):
url = url._replace(path=url.path[len(prefix):])
url = url._replace(path=url.path[len(prefix) :])
return url.geturl()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment