From: Michal Fojtik <[email protected]>

I discover this by creating an instance without name. The error
was reported as 500 (Backend error), but it should be 400 (Bad request).

Signed-off-by: Michal fojtik <[email protected]>
---
 server/lib/deltacloud/drivers/vsphere/vsphere_driver.rb | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/server/lib/deltacloud/drivers/vsphere/vsphere_driver.rb 
b/server/lib/deltacloud/drivers/vsphere/vsphere_driver.rb
index 4f9df5f..5bc7088 100644
--- a/server/lib/deltacloud/drivers/vsphere/vsphere_driver.rb
+++ b/server/lib/deltacloud/drivers/vsphere/vsphere_driver.rb
@@ -380,6 +380,10 @@ module Deltacloud::Drivers::Vsphere
         status 504
       end
 
+      on /missing required parameter name/ do
+        status 400
+      end
+
       on /Invalid/ do
         status 400
       end
-- 
1.8.0.2

Reply via email to