aboutsummaryrefslogtreecommitdiff
path: root/Remote
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2012-08-16 16:36:32 -0700
committerGravatar Joey Hess <joey@kitenet.net>2012-08-16 16:36:32 -0700
commitcbca93cf7cdecc7fd2a66c4640da246462ecc7c7 (patch)
treea2b03b8661a660417c93c75e88a41114c427b7b7 /Remote
parente89c7d3e6af69786458e885fe900c063e2d2af6a (diff)
parent1da4513f4d8c713f167b8e463d7703da5ac2d6a7 (diff)
Merge branch 'master' into assistant
Conflicts: debian/changelog
Diffstat (limited to 'Remote')
-rw-r--r--Remote/S3.hs8
1 files changed, 5 insertions, 3 deletions
diff --git a/Remote/S3.hs b/Remote/S3.hs
index 7dbd096f7..63666bc29 100644
--- a/Remote/S3.hs
+++ b/Remote/S3.hs
@@ -213,9 +213,11 @@ s3Action r noconn action = do
bucketFile :: Remote -> Key -> FilePath
bucketFile r = munge . key2file
where
- munge s = case M.lookup "mungekeys" $ fromJust $ config r of
- Just "ia" -> iaMunge s
- _ -> s
+ munge s = case M.lookup "mungekeys" c of
+ Just "ia" -> iaMunge $ prefix ++ s
+ _ -> prefix ++ s
+ prefix = M.findWithDefault "" "fileprefix" c
+ c = fromJust $ config r
bucketKey :: Remote -> String -> Key -> S3Object
bucketKey r bucket k = S3Object bucket (bucketFile r k) "" [] L.empty