about summary refs log tree commit diff
path: root/third_party/nix/src/libstore/http-binary-cache-store.cc
diff options
context:
space:
mode:
Diffstat (limited to 'third_party/nix/src/libstore/http-binary-cache-store.cc')
-rw-r--r--third_party/nix/src/libstore/http-binary-cache-store.cc8
1 files changed, 6 insertions, 2 deletions
diff --git a/third_party/nix/src/libstore/http-binary-cache-store.cc b/third_party/nix/src/libstore/http-binary-cache-store.cc
index cdef7ca038..2482b02c61 100644
--- a/third_party/nix/src/libstore/http-binary-cache-store.cc
+++ b/third_party/nix/src/libstore/http-binary-cache-store.cc
@@ -23,7 +23,9 @@ class HttpBinaryCacheStore : public BinaryCacheStore {
  public:
   HttpBinaryCacheStore(const Params& params, const Path& _cacheUri)
       : BinaryCacheStore(params), cacheUri(_cacheUri) {
-    if (cacheUri.back() == '/') cacheUri.pop_back();
+    if (cacheUri.back() == '/') {
+      cacheUri.pop_back();
+    }
 
     diskCache = getNarInfoDiskCache();
   }
@@ -57,7 +59,9 @@ class HttpBinaryCacheStore : public BinaryCacheStore {
 
   void checkEnabled() {
     auto state(_state.lock());
-    if (state->enabled) return;
+    if (state->enabled) {
+      return;
+    }
     if (std::chrono::steady_clock::now() > state->disabledUntil) {
       state->enabled = true;
       DLOG(INFO) << "re-enabling binary cache '" << getUri() << "'";