mirror of
https://github.com/ArchiveBox/ArchiveBox.git
synced 2025-05-15 15:44:26 -04:00
refactor: Remove setup_django from html.py
This commit is contained in:
parent
ce53b0220c
commit
57d1a3d4e5
1 changed files with 0 additions and 2 deletions
|
@ -23,7 +23,6 @@ from ..config import (
|
||||||
GIT_SHA,
|
GIT_SHA,
|
||||||
FOOTER_INFO,
|
FOOTER_INFO,
|
||||||
HTML_INDEX_FILENAME,
|
HTML_INDEX_FILENAME,
|
||||||
setup_django,
|
|
||||||
)
|
)
|
||||||
|
|
||||||
MAIN_INDEX_TEMPLATE = 'main_index.html'
|
MAIN_INDEX_TEMPLATE = 'main_index.html'
|
||||||
|
@ -111,7 +110,6 @@ def render_django_template(template: str, context: Mapping[str, str]) -> str:
|
||||||
"""render a given html template string with the given template content"""
|
"""render a given html template string with the given template content"""
|
||||||
from django.template.loader import render_to_string
|
from django.template.loader import render_to_string
|
||||||
|
|
||||||
setup_django(check_db=False)
|
|
||||||
return render_to_string(template, context)
|
return render_to_string(template, context)
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue