summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon MacMullen <simon@rabbitmq.com>2010-06-30 17:21:06 +0100
committerSimon MacMullen <simon@rabbitmq.com>2010-06-30 17:21:06 +0100
commitec28eca027504b57fcfe835705b248caef4fbdaf (patch)
tree314befac83375d5287e100cf52d36dcd027bfb78
parent0d6d3736383e8e6189088c3c9d03c3f17f015de4 (diff)
downloadrabbitmq-server-ec28eca027504b57fcfe835705b248caef4fbdaf.tar.gz
Fix auto-delete on unbind.
-rw-r--r--src/rabbit_exchange.erl8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/rabbit_exchange.erl b/src/rabbit_exchange.erl
index 7072055c..ef818ef4 100644
--- a/src/rabbit_exchange.erl
+++ b/src/rabbit_exchange.erl
@@ -438,11 +438,11 @@ delete_binding(ExchangeName, QueueName, RoutingKey, Arguments, InnerFun) ->
end) of
Err = {error, _} ->
Err;
- {{Action, X = #exchange{ type = Type }}, B} ->
+ {{IsDeleted, X = #exchange{ type = Type }}, B} ->
Module = type_to_module(Type),
- case Action of
- auto_delete -> Module:delete(X, [B]);
- no_delete -> Module:remove_bindings(X, [B])
+ case IsDeleted of
+ auto_deleted -> Module:delete(X, [B]);
+ no_delete -> Module:remove_bindings(X, [B])
end
end.