Skip to content

Commit

Permalink
remove not needed deduplication
Browse files Browse the repository at this point in the history
Fixes #955
  • Loading branch information
lukaszsamson committed Jul 27, 2023
1 parent ddcea61 commit 0fe7b57
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,6 @@ defmodule ElixirLS.LanguageServer.Providers.Completion do
items_json =
items
|> Enum.reject(&is_nil/1)
|> Enum.uniq_by(&{&1.detail, &1.documentation, &1.insert_text})
|> sort_items()
|> items_to_json(options)

Expand Down Expand Up @@ -1118,7 +1117,7 @@ defmodule ElixirLS.LanguageServer.Providers.Completion do

defp sort_items(items) do
Enum.sort_by(items, fn %__MODULE__{priority: priority, label: label} = item ->
# deprioretize deprecated
# deprioritize deprecated
priority =
if item.tags |> Enum.any?(&(&1 == :deprecated)) do
priority + 30
Expand Down

0 comments on commit 0fe7b57

Please sign in to comment.