From 9d42a06c92f0fdc7ca986b738086d361d9b0599b Mon Sep 17 00:00:00 2001 From: Aldo Cortesi Date: Sun, 28 Oct 2012 12:56:08 +1300 Subject: Move message body to new lazy-generator scheme. --- libpathod/app.py | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'libpathod/app.py') diff --git a/libpathod/app.py b/libpathod/app.py index 6f12c0a2..38d0be33 100644 --- a/libpathod/app.py +++ b/libpathod/app.py @@ -123,18 +123,14 @@ def _preview(is_request): args["syntaxerror"] = str(v) args["marked"] = v.marked() return render(template, False, **args) - except language.FileAccessDenied: - args["error"] = "File access is disabled." - return render(template, False, **args) s = cStringIO.StringIO() args["pauses"] = r.preview_safe() - c = app.config["pathod"].check_policy(r) + c = app.config["pathod"].check_policy(r, app.config["pathod"].request_settings) if c: args["error"] = c return render(template, False, **args) - if is_request: r.serve(s, app.config["pathod"].request_settings, host="example.com") else: -- cgit v1.2.3