[refactor] some redundant constraints removed

parent 5d2efe0d
Pipeline #6673 passed with stages
in 64 minutes and 36 seconds
...@@ -131,7 +131,7 @@ stopGargantext scheduledPeriodicActions = do ...@@ -131,7 +131,7 @@ stopGargantext scheduledPeriodicActions = do
-- | Schedules all sorts of useful periodic actions to be run while -- | Schedules all sorts of useful periodic actions to be run while
-- the server is alive accepting requests. -- the server is alive accepting requests.
schedulePeriodicActions :: DB.CmdCommon env => env -> IO [ThreadId] schedulePeriodicActions :: env -> IO [ThreadId]
schedulePeriodicActions _env = schedulePeriodicActions _env =
-- Add your scheduled actions here. -- Add your scheduled actions here.
let actions = [ let actions = [
......
...@@ -61,7 +61,6 @@ import Gargantext.Database.Admin.Types.Node ...@@ -61,7 +61,6 @@ import Gargantext.Database.Admin.Types.Node
import Gargantext.Database.Prelude (Cmd, JSONB) import Gargantext.Database.Prelude (Cmd, JSONB)
import Gargantext.Database.Query.Table.Node import Gargantext.Database.Query.Table.Node
import Gargantext.Database.Query.Table.Node.Children (getChildren) import Gargantext.Database.Query.Table.Node.Children (getChildren)
import Gargantext.Database.Query.Table.Node.Error (HasNodeError(..))
import Gargantext.Database.Query.Table.Node.Update (Update(..), update) import Gargantext.Database.Query.Table.Node.Update (Update(..), update)
import Gargantext.Database.Query.Table.Node.Update qualified as U (update, Update(..)) import Gargantext.Database.Query.Table.Node.Update qualified as U (update, Update(..))
import Gargantext.Database.Query.Table.Node.UpdateOpaleye (updateHyperdata) import Gargantext.Database.Query.Table.Node.UpdateOpaleye (updateHyperdata)
...@@ -187,7 +186,7 @@ treeFlatAPI authenticatedUser rootId = ...@@ -187,7 +186,7 @@ treeFlatAPI authenticatedUser rootId =
rename :: NodeId -> RenameNode -> Cmd err [Int] rename :: NodeId -> RenameNode -> Cmd err [Int]
rename nId (RenameNode name') = U.update (U.Rename nId name') rename nId (RenameNode name') = U.update (U.Rename nId name')
putNode :: forall err a. (HasNodeError err, HyperdataC a) putNode :: forall err a. (HyperdataC a)
=> NodeId => NodeId
-> a -> a
-> Cmd err Int -> Cmd err Int
...@@ -223,7 +222,7 @@ nodeAPI authenticatedUser = Named.NodeAPIEndpoint $ \targetNode -> ...@@ -223,7 +222,7 @@ nodeAPI authenticatedUser = Named.NodeAPIEndpoint $ \targetNode ->
concreteAPI = genericNodeAPI' (Proxy :: Proxy HyperdataAny) authenticatedUser concreteAPI = genericNodeAPI' (Proxy :: Proxy HyperdataAny) authenticatedUser
-- | The /actual/ (generic) node API, instantiated depending on the concrete type of node. -- | The /actual/ (generic) node API, instantiated depending on the concrete type of node.
genericNodeAPI' :: forall a proxy. ( HyperdataC a, Show a, MimeUnrender JSON a, Named.IsGenericNodeRoute a ) genericNodeAPI' :: forall a proxy. ( HyperdataC a )
=> proxy a => proxy a
-> AuthenticatedUser -> AuthenticatedUser
-> NodeId -> NodeId
......
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