deltacloud-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mar...@apache.org
Subject git commit: cimi: exclude created attribute from volume if not returned by driver (fgcp, rhvem)
Date Thu, 29 Nov 2012 07:57:38 GMT
Updated Branches:
  refs/heads/master 71b10c3ab -> 9ef964c5d


cimi: exclude created attribute from volume if not returned by driver (fgcp, rhvem)


Project: http://git-wip-us.apache.org/repos/asf/deltacloud/repo
Commit: http://git-wip-us.apache.org/repos/asf/deltacloud/commit/9ef964c5
Tree: http://git-wip-us.apache.org/repos/asf/deltacloud/tree/9ef964c5
Diff: http://git-wip-us.apache.org/repos/asf/deltacloud/diff/9ef964c5

Branch: refs/heads/master
Commit: 9ef964c5d35712581f8e02065a2da901249b274b
Parents: 71b10c3
Author: Dies Koper <diesk@fast.au.fujitsu.com>
Authored: Thu Nov 29 16:17:47 2012 +0900
Committer: marios <marios@redhat.com>
Committed: Thu Nov 29 09:56:01 2012 +0200

----------------------------------------------------------------------
 server/lib/cimi/models/volume.rb |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/deltacloud/blob/9ef964c5/server/lib/cimi/models/volume.rb
----------------------------------------------------------------------
diff --git a/server/lib/cimi/models/volume.rb b/server/lib/cimi/models/volume.rb
index 9f998ab..d777cd0 100644
--- a/server/lib/cimi/models/volume.rb
+++ b/server/lib/cimi/models/volume.rb
@@ -80,7 +80,7 @@ class CIMI::Model::Volume < CIMI::Model::Base
   def self.from_storage_volume(volume, context)
     self.new( { :name => volume.id,
                 :description => volume.id,
-                :created => Time.parse(volume.created).xmlschema,
+                :created => volume.created.nil? ? nil : Time.parse(volume.created).xmlschema,
                 :id => context.volume_url(volume.id),
                 :capacity => context.to_kibibyte(volume.capacity, 'GB'),
                 :bootable => "false", #fixme ... will vary... ec2 doesn't expose this


Mime
View raw message