From c5a369f185cf17d4418e9089c48819024ad5091d Mon Sep 17 00:00:00 2001 From: Jannis Leidel Date: Fri, 13 May 2011 11:59:29 +0200 Subject: [PATCH] Use the storage directly to get the path. --- compressor/base.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/compressor/base.py b/compressor/base.py index cbd838b..addc3fd 100644 --- a/compressor/base.py +++ b/compressor/base.py @@ -60,10 +60,8 @@ class Compressor(object): if settings.DEBUG and self.finders: filename = self.finders.find(basename) # secondly try finding the file in the root - else: - root_filename = os.path.join(settings.COMPRESS_ROOT, basename) - if os.path.exists(root_filename): - filename = root_filename + elif self.storage.exists(basename): + filename = self.storage.path(basename) if filename: return filename # or just raise an exception as the last resort