Commit d0d92056 authored by Alexandre Delanoë's avatar Alexandre Delanoë

[FIX/SERV] roots with type id.

parent 6927bc06
......@@ -20,7 +20,7 @@ import Database.PostgreSQL.Simple (Connection, connect)
import Opaleye
import Data.Gargantext.Types.Main (Node, NodeId)
import Data.Gargantext.Database.Node (getNodesWithParentId, getNode)
import Data.Gargantext.Database.Node (getNodesWithParentId, getNode, getNodesWithType)
import Data.Gargantext.Database.Private (infoGargandb)
-- | TODO, use MOCK feature of Servant to generate fake data (for tests)
......@@ -37,7 +37,7 @@ type API = "roots" :> Get '[JSON] [Node Value]
server :: Connection -> Server API
server conn
= liftIO (getNodesWithParentId conn null)
= liftIO (getNodesWithType conn 1)
:<|> nodeAPI conn
:<|> echo
:<|> upload
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment