From ca9f9bafd14d8e6517e46c831068bb966c9b5222 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexandre=20Delano=C3=AB?= <devel+git@delanoe.org> Date: Tue, 12 Feb 2019 20:33:33 +0100 Subject: [PATCH] [FIX] so well typed. --- bin/gargantext-import/Main.hs | 2 +- src/Gargantext/API.hs | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/bin/gargantext-import/Main.hs b/bin/gargantext-import/Main.hs index 0d08e6c0..e6877ec4 100644 --- a/bin/gargantext-import/Main.hs +++ b/bin/gargantext-import/Main.hs @@ -28,7 +28,7 @@ import Gargantext.Database.Utils (Cmd, ) import Gargantext.Database.Types.Node (CorpusId) --import Gargantext.Database.Schema.User (insertUsers, gargantuaUser, simpleUser) import Gargantext.API.Node () -- instances -import Gargantext.API.Settings (newDevEnvWith, runCmdDev, cleanEnv, DevEnv) +import Gargantext.API.Settings (newDevEnvWith, runCmdDev, DevEnv) import System.Environment (getArgs) main :: IO () diff --git a/src/Gargantext/API.hs b/src/Gargantext/API.hs index 900bcb93..971e3a82 100644 --- a/src/Gargantext/API.hs +++ b/src/Gargantext/API.hs @@ -278,8 +278,8 @@ type API = SwaggerFrontAPI :<|> GargAPI :<|> Get '[HTML] Html --------------------------------------------------------------------- -- | Server declarations -server :: (HasConnection env, HasRepoVar env) => env - -> IO (Server API) +server :: (HasConnection env, HasRepoVar env, HasRepoSaver env) + => env -> IO (Server API) server env = do -- orchestrator <- scrapyOrchestrator env pure $ swaggerFront @@ -315,7 +315,7 @@ gargMock :: Server GargAPI gargMock = mock apiGarg Proxy --------------------------------------------------------------------- -makeApp :: (HasConnection env, HasRepoVar env) => env -> IO Application +makeApp :: (HasConnection env, HasRepoVar env, HasRepoSaver env) => env -> IO Application makeApp = fmap (serve api) . server appMock :: Application -- 2.21.0