You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@deltacloud.apache.org by jv...@redhat.com on 2012/12/19 21:30:26 UTC

[PATCH] DTACLOUD-398 explicitely specify errors not otherwise caught by sinatra

From: Joe VLcek <jv...@redhat.com>

---
 server/lib/deltacloud/collections/base.rb | 15 +++++++++++----
 1 file changed, 11 insertions(+), 4 deletions(-)

diff --git a/server/lib/deltacloud/collections/base.rb b/server/lib/deltacloud/collections/base.rb
index bc01eff..6562448 100644
--- a/server/lib/deltacloud/collections/base.rb
+++ b/server/lib/deltacloud/collections/base.rb
@@ -43,11 +43,18 @@ module Deltacloud::Collections
       report_error
     end
 
-    error Deltacloud::Exceptions::Conflict do
-      report_error
-    end
+    # error Deltacloud::Exceptions::ObjectNotFound do
+    #   report_error
+    # end
 
-    error Deltacloud::Exceptions::ValidationFailure do
+    error Deltacloud::Exceptions::AcceptedButNotCompletedError,
+          Deltacloud::Exceptions::ValidationFailure,
+          Deltacloud::Exceptions::AuthenticationFailure,
+          Deltacloud::Exceptions::ForbiddenError,
+          Deltacloud::Exceptions::ObjectNotFound,
+          Deltacloud::Exceptions::MethodNotAllowed,
+          Deltacloud::Exceptions::UnknownMediaTypeError,
+          Deltacloud::Exceptions::Conflict do
       report_error
     end
 
-- 
1.7.11.7