From 620c61b51a2760b4fad87a07c51083bc21f4ff66 Mon Sep 17 00:00:00 2001 From: Massimo Di Pierro Date: Tue, 21 Feb 2012 16:26:10 -0600 Subject: [PATCH] improved implementation of Expose, thanks Anthony --- VERSION | 2 +- gluon/tools.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/VERSION b/VERSION index 811a53c6..28fef7d1 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -Version 1.99.4 (2012-02-21 14:03:59) stable +Version 1.99.4 (2012-02-21 16:25:39) stable diff --git a/gluon/tools.py b/gluon/tools.py index 2ab7a37f..0f176dc4 100644 --- a/gluon/tools.py +++ b/gluon/tools.py @@ -4151,7 +4151,7 @@ class Expose(object): def __init__(self,base=None): current.session.forget() base = base or os.path.join(current.request.folder,'static','work') - filename = os.path.join(base,'/'.join(current.request.args)) + filename = os.path.join(base,*current.request.args) if not os.path.isdir(filename): current.response.headers['Content-Type'] = contenttype(filename) raise HTTP(200,open(filename,'rb'),**current.response.headers)