fix: paramaters of type character and bit not ignoring length

- Fixes the error "value too long for type character(1)" when the char length of the parameter was bigger than one.
This commit is contained in:
Laurence Isla
2023-07-31 18:36:37 -05:00
committed by GitHub
parent 0dc67bed0b
commit 40c2bcd4a1
8 changed files with 72 additions and 16 deletions
+2 -2
View File
@@ -154,7 +154,7 @@ makeProcSchema pd =
& required .~ fmap ppName (filter ppReq (pdParams pd))
makeProcProperty :: RoutineParam -> (Text, Referenced Schema)
makeProcProperty (RoutineParam n t _ _) = (n, Inline s)
makeProcProperty (RoutineParam n t _ _ _) = (n, Inline s)
where
s = (mempty :: Schema)
& type_ .~ toSwaggerType t
@@ -181,7 +181,7 @@ makePreferParam ts =
_ -> []
makeProcGetParam :: RoutineParam -> Referenced Param
makeProcGetParam (RoutineParam n t r v) =
makeProcGetParam (RoutineParam n t _ r v) =
Inline $ (mempty :: Param)
& name .~ n
& required ?~ r