3
0
Fork 0
mirror of https://github.com/nanoy42/coope synced 2024-12-27 09:23:47 +00:00
coope/django_tex/engine.py
2019-01-06 15:57:02 +01:00

11 lines
399 B
Python

from django.template.backends.jinja2 import Jinja2
class TeXEngine(Jinja2):
app_dirname = 'templates'
def __init__(self, params):
default_environment = 'django_tex.environment.environment'
if 'environment' not in params['OPTIONS'] or not params['OPTIONS']['environment']:
params['OPTIONS']['environment'] = default_environment
super().__init__(params)