Skip to content

Commit

Permalink
fix: hide private arguments in open api (#247)
Browse files Browse the repository at this point in the history
  • Loading branch information
rapidfsub authored Oct 21, 2024
1 parent 5a573cd commit 76020ae
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/ash_json_api/json_schema/open_api.ex
Original file line number Diff line number Diff line change
Expand Up @@ -1687,6 +1687,7 @@ if Code.ensure_loaded?(OpenApiSpex) do

arguments =
arguments
|> Enum.filter(& &1.public?)
|> without_path_arguments(action, route)
|> without_query_params(route)
|> Enum.reject(& &1.allow_nil?)
Expand Down Expand Up @@ -1716,6 +1717,7 @@ if Code.ensure_loaded?(OpenApiSpex) do
end

arguments
|> Enum.filter(& &1.public?)
|> without_path_arguments(action, route)
|> without_query_params(route)
|> Enum.reduce(attributes, fn argument, attributes ->
Expand Down

0 comments on commit 76020ae

Please sign in to comment.