feat: return post with id

This commit is contained in:
GitBluub
2022-03-05 19:02:08 +01:00
parent cc0b18fc92
commit 18ed95e8a7

View File

@@ -166,8 +166,9 @@ postPipelineHandler (Authenticated (User uid _ _)) x = do
actionId <- createPipeline newPipeline
liftIO $ informWorker "POST" actionId
let newReactions = reactionDatasToReactions (reactions (x :: PostPipelineData)) actionId
let newPipelineWithId = newPipeline { pipelineId = actionId }
createReactions newReactions
return $ formatGetPipelineResponse newPipeline newReactions
return $ formatGetPipelineResponse newPipelineWithId newReactions
where
p = action (x :: PostPipelineData)
postPipelineHandler _ _ = throwError err401