summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon MacMullen <simon@rabbitmq.com>2012-09-17 14:55:20 +0100
committerSimon MacMullen <simon@rabbitmq.com>2012-09-17 14:55:20 +0100
commit1971c67f48bdf3087cafa2330ec7667582a32f33 (patch)
treef5d889dffde4a6750675497f63423314117ffcac
parent82428758641f8ec6d955cb34aade975cdd659d2e (diff)
downloadrabbitmq-server-bug25152.tar.gz
Increase the amount of symmetry.bug25152
-rw-r--r--src/rabbit_binding.erl14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/rabbit_binding.erl b/src/rabbit_binding.erl
index a7730a1a..2e462354 100644
--- a/src/rabbit_binding.erl
+++ b/src/rabbit_binding.erl
@@ -285,13 +285,7 @@ remove_for_destination(DstName) ->
remove_for_destination(DstName, fun remove_routes/1).
remove_transient_for_destination(DstName) ->
- remove_for_destination(
- DstName, fun (Routes) ->
- [begin
- ok = sync_transient_route(R, fun delete_object/3),
- R#route.binding
- end || R <- Routes]
- end).
+ remove_for_destination(DstName, fun remove_transient_routes/1).
%%----------------------------------------------------------------------------
@@ -391,6 +385,12 @@ remove_routes(Routes) ->
R <- DurableRoutes],
[R#route.binding || R <- Routes].
+remove_transient_routes(Routes) ->
+ [begin
+ ok = sync_transient_route(R, fun delete_object/3),
+ R#route.binding
+ end || R <- Routes].
+
remove_for_destination(DstName, Fun) ->
lock_route_tables(),
Match = reverse_route(