aboutsummaryrefslogtreecommitdiffstats
path: root/app/controllers/api_controller.rb
diff options
context:
space:
mode:
authorRobin Houston <robin.houston@gmail.com>2012-05-28 10:28:02 +0100
committerRobin Houston <robin.houston@gmail.com>2012-06-06 19:34:58 +0100
commitc6b9e01f32f5e58a4abf48b6c781906cd914429f (patch)
tree8b065ddbfd5c8a88ec05a0c5f45dad7c08bccc8d /app/controllers/api_controller.rb
parent1a085e3b973726893dc220c060225dc42d9a4edb (diff)
Just include all the error messages
I can’t see any way the error could be triggered by the caller, anyway.
Diffstat (limited to 'app/controllers/api_controller.rb')
-rw-r--r--app/controllers/api_controller.rb6
1 files changed, 1 insertions, 5 deletions
diff --git a/app/controllers/api_controller.rb b/app/controllers/api_controller.rb
index a5b70b8d2..a152813f0 100644
--- a/app/controllers/api_controller.rb
+++ b/app/controllers/api_controller.rb
@@ -46,12 +46,8 @@ class ApiController < ApplicationController
request.outgoing_messages << outgoing_message
# Return an error if the request is invalid
+ # (Can this ever happen?)
if !request.valid?
- # We don't want the error "Outgoing messages is invalid", as in this
- # case the list of errors will also contain a more specific error
- # describing the reason it is invalid.
- info_request.errors.delete("outgoing_messages")
-
render :json => {
'errors' => request.errors.full_messages
}