Location header improvements(#1475)

* Create location header only on primary key columns, closes https://github.com/PostgREST/postgrest/issues/1461

* Return location header when pk columns not selected, fixes https://github.com/PostgREST/postgrest/issues/1162
This commit is contained in:
Wolfgang Walther
2020-07-08 14:36:40 -05:00
committed by GitHub
parent 55b4f4fbe7
commit 343e41c51d
5 changed files with 43 additions and 22 deletions
+1 -1
View File
@@ -361,7 +361,7 @@ app dbStructure proc cols conf apiRequest =
let
readReq = readRequest s t maxRows (dbRelations dbStructure) apiRequest
returnings :: ReadRequest -> Either Response [FieldName]
returnings rr = Right (returningCols rr)
returnings rr = Right (returningCols rr [])
in
(,,,) <$>
(readRequestToQuery <$> readReq) <*>