summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Radestock <matthias@rabbitmq.com>2012-11-27 18:20:34 +0000
committerMatthias Radestock <matthias@rabbitmq.com>2012-11-27 18:20:34 +0000
commit0a808bbfd471334b3a4467e44ef4f07ee1869fc2 (patch)
tree0b0aed5f036adb9cb8040e61766c6661a6aaf2e5
parent554f549a691cbd5d3057ef98914f34d396370012 (diff)
downloadrabbitmq-server-git-0a808bbfd471334b3a4467e44ef4f07ee1869fc2.tar.gz
simplify errors
-rw-r--r--src/rabbit_amqqueue.erl3
-rw-r--r--src/rabbit_amqqueue_process.erl4
2 files changed, 3 insertions, 4 deletions
diff --git a/src/rabbit_amqqueue.erl b/src/rabbit_amqqueue.erl
index c1884118a9..4bdab0bc01 100644
--- a/src/rabbit_amqqueue.erl
+++ b/src/rabbit_amqqueue.erl
@@ -174,8 +174,7 @@
-spec(start_mirroring/1 :: (pid()) -> 'ok').
-spec(stop_mirroring/1 :: (pid()) -> 'ok').
-spec(sync_mirrors/1 :: (rabbit_types:amqqueue()) ->
- 'ok' | rabbit_types:error('queue_has_pending_acks')
- | rabbit_types:error('queue_not_mirrored')).
+ 'ok' | rabbit_types:error('pending_acks' | 'not_mirrored')).
-endif.
diff --git a/src/rabbit_amqqueue_process.erl b/src/rabbit_amqqueue_process.erl
index f7bb4453f6..3f9894f885 100644
--- a/src/rabbit_amqqueue_process.erl
+++ b/src/rabbit_amqqueue_process.erl
@@ -1170,11 +1170,11 @@ handle_call(sync_mirrors, From,
{time_to_shutdown, Reason} ->
{stop, Reason, State}
end;
- _ -> reply({error, queue_has_pending_acks}, State)
+ _ -> reply({error, pending_acks}, State)
end;
handle_call(sync_mirrors, _From, State) ->
- reply({error, queue_not_mirrored}, State);
+ reply({error, not_mirrored}, State);
handle_call(force_event_refresh, _From,
State = #q{exclusive_consumer = Exclusive}) ->