import Gargantext.API.ThrowAll (serverPrivateGargAPI)
import Gargantext.Prelude
import Gargantext.Prelude.Config (gc_url_backend_api)
-import Gargantext.Database.Prelude (config)
+import Gargantext.Database.Prelude (hasConfig)
serverGargAPI :: Text -> GargServerM env err GargAPI
(Proxy :: Proxy GargAPI)
(Proxy :: Proxy AuthContext)
transform
- (serverGargAPI (env ^. config . gc_url_backend_api))
+ (serverGargAPI (env ^. hasConfig . gc_url_backend_api))
:<|> frontEndServer
where
transform :: forall a. GargM env GargError a -> Handler a
showAsServantErr :: GargError -> ServerError
showAsServantErr (GargServerError err) = err
-showAsServantErr a = err500 { errBody = BL8.pack $ show a }
\ No newline at end of file
+showAsServantErr a = err500 { errBody = BL8.pack $ show a }