diff options
Diffstat (limited to 'Logs')
-rw-r--r-- | Logs/NumCopies.hs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Logs/NumCopies.hs b/Logs/NumCopies.hs index a4bca5b07..7593d6c03 100644 --- a/Logs/NumCopies.hs +++ b/Logs/NumCopies.hs @@ -24,7 +24,10 @@ instance SingleValueSerializable NumCopies where deserialize = NumCopies <$$> readish setGlobalNumCopies :: NumCopies -> Annex () -setGlobalNumCopies = setLog numcopiesLog +setGlobalNumCopies new = do + curr <- getGlobalNumCopies + when (curr /= Just new) $ + setLog numcopiesLog new {- Value configured in the numcopies log. Cached for speed. -} getGlobalNumCopies :: Annex (Maybe NumCopies) |