Skip to content

Commit

Permalink
hrl don't have to warning unuse (#1426)
Browse files Browse the repository at this point in the history
  • Loading branch information
CBS-70 authored Dec 21, 2023
1 parent 5dbfa33 commit d263867
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion apps/els_lsp/src/els_unused_includes_diagnostics.erl
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,12 @@ is_default() ->

-spec run(uri()) -> [els_diagnostics:diagnostic()].
run(Uri) ->
case els_utils:lookup_document(Uri) of
%% hrl don't have to warning unuse
case filename:extension(binary_to_list(Uri)) =/= ".hrl"
andalso els_utils:lookup_document(Uri)
of
false ->
[];
{error, _Error} ->
[];
{ok, Document} ->
Expand Down

0 comments on commit d263867

Please sign in to comment.