aboutsummaryrefslogtreecommitdiffstats
path: root/libpathod/app.py
diff options
context:
space:
mode:
Diffstat (limited to 'libpathod/app.py')
-rw-r--r--libpathod/app.py10
1 files changed, 6 insertions, 4 deletions
diff --git a/libpathod/app.py b/libpathod/app.py
index 6478964c..79c0fc71 100644
--- a/libpathod/app.py
+++ b/libpathod/app.py
@@ -28,6 +28,8 @@ def api():
def render(s, **kwargs):
kwargs["noapi"] = app.config["pathod"].noapi
+ kwargs["nocraft"] = app.config["pathod"].nocraft
+ kwargs["craftanchor"] = app.config["pathod"].craftanchor
return render_template(s, **kwargs)
@@ -87,13 +89,13 @@ def response_preview():
except rparse.ParseException, v:
args["syntaxerror"] = str(v)
args["marked"] = v.marked()
- return render("preview_response.html", **args)
+ return render("response_preview.html", **args)
s = cStringIO.StringIO()
r.preview_safe()
r.serve(s, check=app.config["pathod"].check_size)
args["output"] = utils.escape_unprintables(s.getvalue())
- return render("preview_response.html", **args)
+ return render("response_preview.html", **args)
@app.route('/request_preview')
@@ -110,10 +112,10 @@ def request_preview():
except rparse.ParseException, v:
args["syntaxerror"] = str(v)
args["marked"] = v.marked()
- return render("preview_request.html", **args)
+ return render("request_preview.html", **args)
s = cStringIO.StringIO()
r.preview_safe()
r.serve(s, check=app.config["pathod"].check_size, host="example.com")
args["output"] = utils.escape_unprintables(s.getvalue())
- return render("preview_request.html", **args)
+ return render("request_preview.html", **args)