fix: Fix requests for overloaded functions from html forms to no longer hang

Fixes #1846
This commit is contained in:
Laurence Isla
2021-05-13 10:07:49 +02:00
committed by Wolfgang Walther
parent 082c91c855
commit b4ca70708a
3 changed files with 47 additions and 3 deletions
+3 -3
View File
@@ -243,9 +243,9 @@ userApiRequest conf@AppConfig{..} dbStructure req reqBody
parsedColumns = pRequestColumns columns
payloadColumns =
case (contentType, action) of
(_, ActionInvoke InvGet) -> S.fromList $ fst <$> rpcQParams
(_, ActionInvoke InvHead) -> S.fromList $ fst <$> rpcQParams
(CTOther "application/x-www-form-urlencoded", _) -> S.fromList $ map (toS . fst) $ parseSimpleQuery $ toS reqBody
(_, ActionInvoke InvGet) -> S.fromList $ fst <$> rpcQParams
(_, ActionInvoke InvHead) -> S.fromList $ fst <$> rpcQParams
(CTUrlEncoded, _) -> S.fromList $ map (toS . fst) $ parseSimpleQuery $ toS reqBody
_ -> case (relevantPayload, fromRight Nothing parsedColumns) of
(Just ProcessedJSON{pjKeys}, _) -> pjKeys
(Just RawJSON{}, Just cls) -> cls