summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Radestock <matthias@rabbitmq.com>2011-03-28 21:13:36 +0100
committerMatthias Radestock <matthias@rabbitmq.com>2011-03-28 21:13:36 +0100
commit6465f6639b0e73f4080317dec82fac1e7397e090 (patch)
treead9578ce58f59602246447bcf5717b2eeb983116
parentb5676465bfed9d4dda43b50043c2d67b5b595e2e (diff)
downloadrabbitmq-server-6465f6639b0e73f4080317dec82fac1e7397e090.tar.gz
tweak: only invoke rabbit_exchange:callback when absolutely necessary
-rw-r--r--src/rabbit_exchange.erl2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/rabbit_exchange.erl b/src/rabbit_exchange.erl
index b5d38b75..cab6510b 100644
--- a/src/rabbit_exchange.erl
+++ b/src/rabbit_exchange.erl
@@ -131,7 +131,7 @@ declare(XName, Type, Durable, AutoDelete, Internal, Args) ->
end
end,
fun ({new, Exchange}, Tx) ->
- callback(Exchange, create, [Tx, Exchange]),
+ ok = (type_to_module(Type)):create(Tx, Exchange),
rabbit_event:notify_if(not Tx, exchange_created, info(Exchange)),
Exchange;
({existing, Exchange}, _Tx) ->