diff options
author | Eelco Dolstra <edolstra@gmail.com> | 2017-03-14 15:26:01 +0100 |
---|---|---|
committer | Eelco Dolstra <edolstra@gmail.com> | 2017-03-15 16:50:19 +0100 |
commit | 45c70382ac152107d40956c6a3ab8c329086733f (patch) | |
tree | f99d8dddffd7ed5ae1b823572c9bbaf0cf2af276 /src/libstore/local-binary-cache-store.cc | |
parent | 8b1d65bebe5af8960ba813e1233f2596a3ffebb7 (diff) |
S3BinaryCacheStore: Set Content-Type
This is necessary for serving log files to browsers.
Diffstat (limited to 'src/libstore/local-binary-cache-store.cc')
-rw-r--r-- | src/libstore/local-binary-cache-store.cc | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/libstore/local-binary-cache-store.cc b/src/libstore/local-binary-cache-store.cc index 0f377989b..aff22f9fc 100644 --- a/src/libstore/local-binary-cache-store.cc +++ b/src/libstore/local-binary-cache-store.cc @@ -30,7 +30,9 @@ protected: bool fileExists(const std::string & path) override; - void upsertFile(const std::string & path, const std::string & data) override; + void upsertFile(const std::string & path, + const std::string & data, + const std::string & mimeType) override; void getFile(const std::string & path, std::function<void(std::shared_ptr<std::string>)> success, @@ -83,7 +85,9 @@ bool LocalBinaryCacheStore::fileExists(const std::string & path) return pathExists(binaryCacheDir + "/" + path); } -void LocalBinaryCacheStore::upsertFile(const std::string & path, const std::string & data) +void LocalBinaryCacheStore::upsertFile(const std::string & path, + const std::string & data, + const std::string & mimeType) { atomicWrite(binaryCacheDir + "/" + path, data); } |