Merge "getFileContents: Remove unused StringSink" into main
This commit is contained in:
committed by
Lix Systems Gerrit
commit
f963bd8295
@@ -72,13 +72,11 @@ void BinaryCacheStore::upsertFile(const std::string & path,
|
||||
|
||||
std::optional<std::string> BinaryCacheStore::getFileContents(const std::string & path)
|
||||
{
|
||||
StringSink sink;
|
||||
try {
|
||||
return getFile(path)->drain();
|
||||
} catch (NoSuchBinaryCacheFile &) {
|
||||
return std::nullopt;
|
||||
}
|
||||
return std::move(sink.s);
|
||||
}
|
||||
|
||||
std::string BinaryCacheStore::narInfoFileFor(const StorePath & storePath)
|
||||
|
||||
Reference in New Issue
Block a user