diff options
author | Matthias Radestock <matthias@rabbitmq.com> | 2012-05-04 10:25:08 +0100 |
---|---|---|
committer | Matthias Radestock <matthias@rabbitmq.com> | 2012-05-04 10:25:08 +0100 |
commit | 0960e22cb63aa8499cf6a3aa3ae78e70547c2349 (patch) | |
tree | e11d5e0fbfe2bd83ac062c030558cb3403c1daeb | |
parent | 0c3c0032613885300b5fcdd0c465c23f71fe1ed6 (diff) | |
download | rabbitmq-server-0960e22cb63aa8499cf6a3aa3ae78e70547c2349.tar.gz |
cosmetic
-rw-r--r-- | src/rabbit_plugins.erl | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/src/rabbit_plugins.erl b/src/rabbit_plugins.erl index 1d165f3f..00880fb2 100644 --- a/src/rabbit_plugins.erl +++ b/src/rabbit_plugins.erl @@ -245,7 +245,7 @@ format_plugins(Pattern, Opts, PluginsFile, PluginsDir) -> {true, true} -> throw({error_string, "Cannot specify -m and -v together"}) end, - OnlyEnabled = proplists:get_bool(?ENABLED_OPT, Opts), + OnlyEnabled = proplists:get_bool(?ENABLED_OPT, Opts), OnlyEnabledAll = proplists:get_bool(?ENABLED_ALL_OPT, Opts), AvailablePlugins = find_plugins(PluginsDir), @@ -257,14 +257,10 @@ format_plugins(Pattern, Opts, PluginsFile, PluginsDir) -> Plugins = [ Plugin || Plugin = #plugin{name = Name} <- AvailablePlugins, re:run(atom_to_list(Name), RE, [{capture, none}]) =:= match, - if OnlyEnabled -> lists:member(Name, EnabledExplicitly); - true -> true - end, - if OnlyEnabledAll -> - lists:member(Name, EnabledImplicitly) or - lists:member(Name, EnabledExplicitly); - true -> - true + if OnlyEnabled -> lists:member(Name, EnabledExplicitly); + OnlyEnabledAll -> (lists:member(Name, EnabledExplicitly) or + lists:member(Name, EnabledImplicitly)); + true -> true end], Plugins1 = usort_plugins(Plugins), MaxWidth = lists:max([length(atom_to_list(Name)) || |