mirror of
https://expo.survex.com/repositories/expoweb/.git/
synced 2024-11-21 23:01:55 +00:00
fix trailing hyphen
This commit is contained in:
parent
89a8ddb670
commit
0c2b5e095f
@ -35,6 +35,7 @@ def troggle_slugify(longname):
|
||||
slug = slug.replace('&', '') # otherwise just remove the &
|
||||
slug = slug.replace(';', '') # otherwise just remove the ;
|
||||
slug = re.sub(r'<[^>]*>','',slug) # remove <span-lang = "hu">
|
||||
slug=slug.strip("-") # remove spare hyphens
|
||||
|
||||
if len(slug) > 40: # slugfield is 50 chars
|
||||
slug = slug[:40]
|
||||
|
Loading…
Reference in New Issue
Block a user