support raise in template

This commit is contained in:
egarette@silique.fr 2023-06-22 15:45:05 +02:00
parent 7f745b3609
commit 0b0503e109

View file

@ -0,0 +1,11 @@
from jinja2.exceptions import TemplateRuntimeError
def fraise(msg):
raise TemplateRuntimeError(msg)
class FilterModule:
def filters(self):
return {
'raise': fraise,
}