summaryrefslogtreecommitdiff
path: root/src/rabbit_misc.erl
diff options
context:
space:
mode:
authorBen Hood <0x6e6562@gmail.com>2008-09-27 21:51:23 +0100
committerBen Hood <0x6e6562@gmail.com>2008-09-27 21:51:23 +0100
commit733ac828df24d7ddcbc534e24627128df565a610 (patch)
treee7f1a7e18f9e3a82e0f40ceb04815421184ef254 /src/rabbit_misc.erl
parentf062146dc1dcf8c148162b7db1febdd711a89129 (diff)
downloadrabbitmq-server-733ac828df24d7ddcbc534e24627128df565a610.tar.gz
Removed e_m_t/2
Diffstat (limited to 'src/rabbit_misc.erl')
-rw-r--r--src/rabbit_misc.erl10
1 files changed, 3 insertions, 7 deletions
diff --git a/src/rabbit_misc.erl b/src/rabbit_misc.erl
index 1c9d299f..e432db59 100644
--- a/src/rabbit_misc.erl
+++ b/src/rabbit_misc.erl
@@ -36,7 +36,7 @@
-export([enable_cover/0, report_cover/0]).
-export([with_exit_handler/2]).
-export([with_user/2, with_vhost/2, with_user_and_vhost/3]).
--export([execute_mnesia_transaction/1, execute_mnesia_transaction/2]).
+-export([execute_mnesia_transaction/1]).
-export([ensure_ok/2]).
-export([localnode/1, tcp_name/3]).
-export([intersperse/2, upmap/2, map_in_order/2]).
@@ -81,8 +81,7 @@
-spec(with_user/2 :: (username(), thunk(A)) -> A).
-spec(with_vhost/2 :: (vhost(), thunk(A)) -> A).
-spec(with_user_and_vhost/3 :: (username(), vhost(), thunk(A)) -> A).
--spec(execute_mnesia_transaction/1 :: (thunk(A) | function(A)) -> A).
--spec(execute_mnesia_transaction/2 :: (thunk(A) | function(A), list()) -> A).
+-spec(execute_mnesia_transaction/1 :: (thunk(A)) -> A).
-spec(ensure_ok/2 :: ('ok' | {'error', any()}, atom()) -> 'ok').
-spec(localnode/1 :: (atom()) -> node()).
-spec(tcp_name/3 :: (atom(), ip_address(), ip_port()) -> atom()).
@@ -234,10 +233,7 @@ with_user_and_vhost(Username, VHostPath, Thunk) ->
%% elsewhere and get a consistent result even when that read
%% executes on a different node.
execute_mnesia_transaction(TxFun) ->
- execute_mnesia_transaction(TxFun, []).
-
-execute_mnesia_transaction(TxFun, Args) ->
- case mnesia:sync_transaction(TxFun, Args) of
+ case mnesia:sync_transaction(TxFun) of
{atomic, Result} -> Result;
{aborted, Reason} -> throw({error, Reason})
end.