9 lines
152 B
Python
9 lines
152 B
Python
|
from django import template
|
||
|
|
||
|
register = template.Library()
|
||
|
|
||
|
|
||
|
@register.filter(is_safe=True)
|
||
|
def to_navbar_text(path):
|
||
|
return "~/" + path.strip("/")
|