detect when unwanted remote is empty and remove it
Needs fixes to build when the webapp is disabled.
This commit is contained in:
parent
8a5b397ac4
commit
9a5f421768
13 changed files with 157 additions and 42 deletions
|
@ -13,6 +13,7 @@ module Logs.Group (
|
|||
groupMap,
|
||||
groupMapLoad,
|
||||
getStandardGroup,
|
||||
inUnwantedGroup
|
||||
) where
|
||||
|
||||
import qualified Data.Map as M
|
||||
|
@ -74,3 +75,7 @@ getStandardGroup :: S.Set Group -> Maybe StandardGroup
|
|||
getStandardGroup s = case mapMaybe toStandardGroup $ S.toList s of
|
||||
[g] -> Just g
|
||||
_ -> Nothing
|
||||
|
||||
inUnwantedGroup :: UUID -> Annex Bool
|
||||
inUnwantedGroup u = elem UnwantedGroup
|
||||
. mapMaybe toStandardGroup . S.toList <$> lookupGroups u
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue