Skip to content

Commit

Permalink
apply formatter
Browse files Browse the repository at this point in the history
  • Loading branch information
nsidnev committed Oct 10, 2023
1 parent f3687c3 commit f73480c
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 3 deletions.
7 changes: 6 additions & 1 deletion lib/edgedb/edgeql/generator.ex
Original file line number Diff line number Diff line change
Expand Up @@ -383,7 +383,12 @@ defmodule EdgeDB.EdgeQL.Generator do
defp codec_to_shape(%Codecs.Enum{name: type_name, members: members}, _codec_storage) do
full_type_name = full_name_to_typespec(type_name)
typedoc = "scalar type #{type_name} extending enum<#{Enum.join(members, ", ")}>"
register_typespec(full_type_name, {typedoc, ["String.t()" | Enum.map(members, &":#{inspect(&1)}")]})

register_typespec(
full_type_name,
{typedoc, ["String.t()" | Enum.map(members, &":#{inspect(&1)}")]}
)

%{type: :builtin, typespec: full_type_name}
end

Expand Down
6 changes: 5 additions & 1 deletion lib/edgedb/error.ex
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,11 @@ defmodule EdgeDB.Error do
"#{exception.name}: #{exception.message}"
end

defp generate_render_config(%__MODULE__{query: %EdgeDB.Query{}} = exception, true, color_errors?) do
defp generate_render_config(
%__MODULE__{query: %EdgeDB.Query{}} = exception,
true,
color_errors?
) do
position_start =
case Integer.parse(exception.attributes[:character_start] || "") do
{position_start, ""} ->
Expand Down
2 changes: 1 addition & 1 deletion lib/edgedb/query.ex
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ defmodule EdgeDB.Query do
codec_storage: nil,
cached: false,
params: [],
__file__: nil,
__file__: nil
]

@type t() :: %__MODULE__{
Expand Down

0 comments on commit f73480c

Please sign in to comment.