[PATCH conductor] RM3244: fix minor issues

mzatko at redhat.com mzatko at redhat.com
Sun Jun 3 15:54:21 UTC 2012


From: Maros Zatko <mzatko at redhat.com>

---
 src/app/util/deployable_xml.rb      |    8 ++++----
 src/app/util/instance_config_xml.rb |    4 ++--
 2 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/src/app/util/deployable_xml.rb b/src/app/util/deployable_xml.rb
index dea460f..cdbbc39 100644
--- a/src/app/util/deployable_xml.rb
+++ b/src/app/util/deployable_xml.rb
@@ -196,8 +196,8 @@ class DeployableXML
     if xmlstr_or_node.is_a? Nokogiri::XML::Node
       @root = xmlstr_or_node
     elsif xmlstr_or_node.is_a? String
-      @doc = Nokogiri::XML(xmlstr_or_node) { |config| config.strict }
-      @root = @doc.root.at_xpath("/deployable") if @doc.root
+      doc = Nokogiri::XML(xmlstr_or_node) { |config| config.strict }
+      @root = doc.root.at_xpath("/deployable") if doc.root
     end
     @relax_file = "#{File.dirname(File.expand_path(__FILE__))}/deployable-rng.xml"
   end
@@ -233,8 +233,8 @@ class DeployableXML
   def assemblies
     @assemblies ||=
       @root.xpath('/deployable/assemblies/assembly').collect do |assembly_node|
-      AssemblyXML.new(assembly_node)
-    end
+        AssemblyXML.new(assembly_node)
+      end
   end
 
   def image_uuids
diff --git a/src/app/util/instance_config_xml.rb b/src/app/util/instance_config_xml.rb
index c170f2c..37017f4 100644
--- a/src/app/util/instance_config_xml.rb
+++ b/src/app/util/instance_config_xml.rb
@@ -18,8 +18,8 @@ class InstanceConfigXML
   class ValidationError < RuntimeError; end
 
   def initialize(xmlstr = "")
-    @doc = Nokogiri::XML(xmlstr)
-    @root = @doc.root.at_xpath('/instance-config') if @doc.root
+    doc = Nokogiri::XML(xmlstr)
+    @root = doc.root.at_xpath('/instance-config') if doc.root
   end
 
   def to_s
-- 
1.7.10.2




More information about the aeolus-devel mailing list