summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon MacMullen <simon@rabbitmq.com>2012-07-04 17:39:57 +0100
committerSimon MacMullen <simon@rabbitmq.com>2012-07-04 17:39:57 +0100
commit19f554ed69bf144b6d83d86a3ea6cc4eeac41448 (patch)
tree300fc04a424591dc182522b000a985240512b7ac
parentf060804469e9335ccb67f80ae5132a33d96747a2 (diff)
downloadrabbitmq-server-git-19f554ed69bf144b6d83d86a3ea6cc4eeac41448.tar.gz
Cosmetic: indulge bias against if statements.
-rwxr-xr-xcheck_xref20
1 files changed, 10 insertions, 10 deletions
diff --git a/check_xref b/check_xref
index 382767bb2d..55458c6684 100755
--- a/check_xref
+++ b/check_xref
@@ -70,14 +70,13 @@ check(Cwd, PluginsDir, LibDir, Checks) ->
ok = file:rename(UnpackDir, AppN),
code:add_patha(filename:join(AppN, "ebin")),
- if IsExternal =:= true ->
- App = list_to_atom(hd(string:tokens(filename:basename(AppN),
- "-"))),
- report(info, "loading ~p~n", [App]),
- application:load(App),
- store_third_party(App);
- true ->
- ok
+ case IsExternal of
+ true -> App = list_to_atom(hd(string:tokens(filename:basename(AppN),
+ "-"))),
+ report(info, "loading ~p~n", [App]),
+ application:load(App),
+ store_third_party(App);
+ _ -> ok
end
end || Plugin <- Plugins,
lists:suffix(".ez", Plugin)],
@@ -220,8 +219,9 @@ report(Results) ->
{Errors, Warnings} = partition(Results),
report(info, "Completed: ~p errors, ~p warnings~n",
[length(Errors), length(Warnings)]),
- if length(Errors) > 0 -> halt(1);
- true -> halt(0)
+ case length(Errors) > 0 of
+ true -> halt(1);
+ false -> halt(0)
end.
report_failures({analysis_error, {Mod, Reason}}) ->