mirror of
https://github.com/correl/rebar.git
synced 2024-12-18 03:00:17 +00:00
Use an order independent method for exact matches when looking for command candidates
This commit is contained in:
parent
6978504d43
commit
a8066b35a9
1 changed files with 3 additions and 3 deletions
|
@ -258,9 +258,9 @@ get_command_name_candidates(Command) ->
|
||||||
is_command_name_candidate(Command, Candidate)],
|
is_command_name_candidate(Command, Candidate)],
|
||||||
%% Is there a complete match? If so return only that, return a
|
%% Is there a complete match? If so return only that, return a
|
||||||
%% list of candidates otherwise
|
%% list of candidates otherwise
|
||||||
case Candidates of
|
case lists:member(Command, Candidates) of
|
||||||
[Command] = Match -> Match;
|
true -> [Command];
|
||||||
_ -> Candidates
|
false -> Candidates
|
||||||
end.
|
end.
|
||||||
|
|
||||||
is_command_name_candidate(Command, Candidate) ->
|
is_command_name_candidate(Command, Candidate) ->
|
||||||
|
|
Loading…
Reference in a new issue