deltacloud-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mfoj...@apache.org
Subject [1/2] git commit: Removing comma if no info follows in instances view
Date Mon, 30 Apr 2012 13:10:19 GMT
Updated Branches:
  refs/heads/master 2b449f17e -> 48e3efca8


Removing comma if no info follows in instances view


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

Branch: refs/heads/master
Commit: 48e3efca857b1b0584434e56640c210a2e9e41ed
Parents: cc3dba2
Author: Dies Koper <diesk@fast.au.fujitsu.com>
Authored: Mon Apr 30 22:48:42 2012 +1000
Committer: Michal fojtik <mfojtik@redhat.com>
Committed: Mon Apr 30 15:10:11 2012 +0200

----------------------------------------------------------------------
 .../deltacloud/helpers/hardware_profiles_helper.rb |    2 +-
 server/views/instances/show.html.haml              |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/deltacloud/blob/48e3efca/server/lib/deltacloud/helpers/hardware_profiles_helper.rb
----------------------------------------------------------------------
diff --git a/server/lib/deltacloud/helpers/hardware_profiles_helper.rb b/server/lib/deltacloud/helpers/hardware_profiles_helper.rb
index 4da9d8c..af2100e 100644
--- a/server/lib/deltacloud/helpers/hardware_profiles_helper.rb
+++ b/server/lib/deltacloud/helpers/hardware_profiles_helper.rb
@@ -34,7 +34,7 @@ module HardwareProfilesHelper
       "#{p} = #{v} #{u}"
     end
     if o.empty?
-      ""
+      nil
     else
       "with #{o.join(", ")}"
     end

http://git-wip-us.apache.org/repos/asf/deltacloud/blob/48e3efca/server/views/instances/show.html.haml
----------------------------------------------------------------------
diff --git a/server/views/instances/show.html.haml b/server/views/instances/show.html.haml
index b91b71e..72dc12d 100644
--- a/server/views/instances/show.html.haml
+++ b/server/views/instances/show.html.haml
@@ -19,7 +19,7 @@
     %li
       - prof = @instance.instance_profile
       %a{ :href => hardware_profile_url(prof.name), :'data-ajax' => 'false'}
-        =[prof.name, format_instance_profile(prof)].join(', ')
+        =[prof.name, format_instance_profile(prof)].compact.join(', ')
     %li{ :'data-role' => 'list-divider'} Realm
     %li
       - if @instance.realm_id


Mime
View raw message