From 5122fbe110779ff417888e45e153d0e7ae44cf30 Mon Sep 17 00:00:00 2001 From: Massimo Date: Fri, 8 Mar 2013 10:16:48 -0600 Subject: [PATCH] fixed issue 1366, minor rewrite in retrieve, thanks Dominic --- VERSION | 2 +- gluon/dal.py | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/VERSION b/VERSION index acad1af6..a39f4e8f 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -Version 2.4.2-stable+timestamp.2013.03.08.10.05.09 +Version 2.4.2-stable+timestamp.2013.03.08.10.16.16 diff --git a/gluon/dal.py b/gluon/dal.py index 56e2eb8a..0ee8066e 100644 --- a/gluon/dal.py +++ b/gluon/dal.py @@ -9262,7 +9262,8 @@ class Field(Expression): stream = self.uploadfs.open(name, 'rb') else: # ## if file is on regular filesystem - stream = pjoin(file_properties['path'], name) + fullname = pjoin(file_properties['path'], name) + stream = open(fullname,'rb') return (filename, stream) def retrieve_file_properties(self, name, path=None):