fix: bad M2M embed on RPC

This commit is contained in:
steve-chavez
2022-11-18 17:49:24 -05:00
committed by Steve Chavez
parent cca0b5ae66
commit cb99270a8f
7 changed files with 39 additions and 18 deletions
-7
View File
@@ -1,8 +1,6 @@
{-# LANGUAGE NamedFieldPuns #-}
module PostgREST.Plan.ReadPlan
( ReadPlanTree
, ReadPlan(..)
, fstFieldNames
, JoinCondition(..)
) where
@@ -46,8 +44,3 @@ data ReadPlan = ReadPlan
-- ^ used for aliasing
}
deriving (Eq)
-- First level FieldNames(e.g get a,b from /table?select=a,b,other(c,d))
fstFieldNames :: ReadPlanTree -> [FieldName]
fstFieldNames (Node ReadPlan{select} _) =
fst . (\(f, _, _) -> f) <$> select