Skip to content

Commit

Permalink
gogol: formatting newEnv{,With} type signatures
Browse files Browse the repository at this point in the history
  • Loading branch information
brendanhay committed Apr 6, 2022
1 parent af5b1a2 commit 494098a
Showing 1 changed file with 13 additions and 4 deletions.
17 changes: 13 additions & 4 deletions lib/gogol/src/Gogol/Env.hs
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ class HasEnv scopes a | a -> scopes where
envLogger = environment . lens _envLogger (\s a -> s {_envLogger = a})
envManager = environment . lens _envManager (\s a -> s {_envManager = a})
envStore = environment . lens _envStore (\s a -> s {_envStore = a})
envScopes = environment . lens (\_ -> Proxy :: Proxy s) (flip allow)
envScopes = environment . lens (\_ -> Proxy :: Proxy scopes) (flip allow)

instance HasEnv scopes (Env scopes) where
environment = id
Expand Down Expand Up @@ -127,7 +127,13 @@ timeout s = local (configure (serviceTimeout ?~ s))
-- Lenses from 'HasEnv' can be used to further configure the resulting 'Env'.
--
-- /See:/ 'newEnvWith', 'getApplicationDefault'.
newEnv :: forall s. m (MonadIO m, MonadCatch m, KnownScopes scopes) => m (Env scopes)
newEnv ::
forall scopes m.
( MonadIO m,
MonadCatch m,
KnownScopes scopes
) =>
m (Env scopes)
newEnv = do
m <- liftIO (newManager tlsManagerSettings)
c <- getApplicationDefault m
Expand All @@ -137,8 +143,11 @@ newEnv = do
--
-- /See:/ 'newEnv'.
newEnvWith ::
forall s m.
(MonadIO m, MonadCatch m, KnownScopes scopes) =>
forall scopes m.
( MonadIO m,
MonadCatch m,
KnownScopes scopes
) =>
Credentials scopes ->
Logger ->
Manager ->
Expand Down

0 comments on commit 494098a

Please sign in to comment.