Changes
1 changed files (+11/-9)
-
-
@@ -191,18 +191,20 @@parseLoops : Fields -> Result Errors Parameters.Loops parseLoops fields = case ( parseFixedLoop fields, parseFreeLoop fields, parseField LoopStyle parseLoopStyle fields ) of ( Ok fixed, Ok free, Ok style ) -> let base = Parameters.default.shortPiece.loops in Ok { base | fixed = fixed, free = free, style = style } case ( ( parseFixedLoop fields, parseFreeLoop fields ) , ( parseField LoopStyle parseLoopStyle fields , parseField LoopThickness (parseLength constraints.shortPiece.loops.thickness) fields ) ) of ( ( Ok fixed, Ok free ), ( Ok style, Ok thickness ) ) -> Ok { fixed = fixed, free = free, style = style, thickness = thickness } ( fixed, free, style ) -> ( ( fixed, free ), ( style, thickness ) ) -> [ getError fixed |> Maybe.withDefault Dict.empty , getError free |> Maybe.withDefault Dict.empty , mkErrors [ ( LoopStyle, getError style ) ] , mkErrors [ ( LoopStyle, getError style ), ( LoopThickness, getError thickness ) ] ] |> List.map Dict.toList |> List.concat
-