summaryrefslogtreecommitdiff
path: root/Annex.hs
diff options
context:
space:
mode:
Diffstat (limited to 'Annex.hs')
-rw-r--r--Annex.hs4
1 files changed, 1 insertions, 3 deletions
diff --git a/Annex.hs b/Annex.hs
index 9915112a5..b2257281f 100644
--- a/Annex.hs
+++ b/Annex.hs
@@ -86,9 +86,7 @@ getState c = liftM c get
- Example: changeState (\s -> s { quiet = True })
-}
changeState :: (AnnexState -> AnnexState) -> Annex ()
-changeState a = do
- state <- get
- put (a state)
+changeState a = put . a =<< get
{- Returns the git repository being acted on -}
gitRepo :: Annex Git.Repo