On 26/01/11 16:16 -0800, [email protected] wrote:

Good catch David! ACK.

  -- Michal

From: David Lutterkort <[email protected]>

Before, running 'deltacloudc realms' would raise the exception

 ./lib/plain_formatter.rb:81:in `const_get': wrong constant name Base::Realm
---
client/lib/plain_formatter.rb |    2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/client/lib/plain_formatter.rb b/client/lib/plain_formatter.rb
index e17a5e6..cc75ec1 100644
--- a/client/lib/plain_formatter.rb
+++ b/client/lib/plain_formatter.rb
@@ -77,7 +77,7 @@ module DeltaCloud
    end

    def format(obj)
-      object_name = obj.class.name.classify.gsub(/^DeltaCloud::API::/, '')
+      object_name = obj.class.name.classify.gsub(/^.*::/, '')
      format_class = 
DeltaCloud::PlainFormatter::FormatObject.const_get(object_name)
      format_class.new(obj).format
    end
--
1.7.3.5


--
--------------------------------------------------------
Michal Fojtik, [email protected]
Deltacloud API: http://deltacloud.org
--------------------------------------------------------

Reply via email to