Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions djangosphinx/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,16 @@

if 'coffin' in settings.INSTALLED_APPS:
import jinja2
from coffin import shortcuts
from coffin.shortcuts import render_to_string as dj_render_to_string
else:
from django import shortcuts
from django.template.loader import render_to_string as dj_render_to_string

def render_to_string(template, context, request=None):
if request:
context_instance = RequestContext(request)
else:
context_instance = None
return shortcuts.render_to_string(template, context, context_instance)
return dj_render_to_string(template, context, context_instance)

def relative_path(*args):
return os.path.abspath(os.path.join(settings.SPHINX_ROOT, *args))
Expand Down