finish fixing inverted Ord for TrustLevel
Flipped all comparisons. When a TrustLevel list was wanted from Trusted downwards, used Down to compare it in that order. This commit was sponsored by mo on Patreon.
This commit is contained in:
parent
a0e4b9678b
commit
f56594af9e
7 changed files with 22 additions and 19 deletions
|
@ -72,7 +72,7 @@ trustMapLoad = do
|
|||
map (\r -> (Types.Remote.uuid r, UnTrusted)) exports
|
||||
logged <- trustMapRaw
|
||||
let configured = M.fromList $ mapMaybe configuredtrust l
|
||||
let m = --M.unionWith max exportoverrides $
|
||||
let m = M.unionWith min exportoverrides $
|
||||
M.union overrides $
|
||||
M.union configured logged
|
||||
Annex.changeState $ \s -> s { Annex.trustmap = Just m }
|
||||
|
|
|
@ -31,6 +31,6 @@ showTrustLog DeadTrusted = "X"
|
|||
showTrustLog SemiTrusted = "?"
|
||||
|
||||
prop_parse_show_TrustLog :: Bool
|
||||
prop_parse_show_TrustLog = True -- all check [minBound .. maxBound]
|
||||
prop_parse_show_TrustLog = all check [minBound .. maxBound]
|
||||
where
|
||||
check l = parseTrustLog (showTrustLog l) == l
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue