indent-wheres
| Description | Whether to full-indent or half-indent 'where' bindings past the preceding body |
|---|---|
| Type | Bool |
| Default | false |
| Ormolu | true |
| Since | v0.2.0.0 |
Examples
setPassword :: String -> String -> IO ()
setPassword username password = do
user <- getUser username >>= maybe userNotFound pure
hash <- hashPassword password
saveUser user{userPasswordHash = hash}
where
userNotFound = error $ "User not found: " ++ username
setPassword :: String -> String -> IO ()
setPassword username password = do
user <- getUser username >>= maybe userNotFound pure
hash <- hashPassword password
saveUser user{userPasswordHash = hash}
where
userNotFound = error $ "User not found: " ++ username
For more examples, see the test files.