]> git.cworth.org Git - sup/commitdiff
minor misc code tweaks
authorWilliam Morgan <wmorgan-sup@masanjin.net>
Wed, 19 Aug 2009 18:34:27 +0000 (14:34 -0400)
committerWilliam Morgan <wmorgan-sup@masanjin.net>
Wed, 19 Aug 2009 18:34:27 +0000 (14:34 -0400)
lib/sup/source.rb
lib/sup/util.rb

index 0705a75498607d192223fb1f2a3abc4ad960b5c3..a557bd857c815232b07601f98d713fa9ae26ff2c 100644 (file)
@@ -225,7 +225,7 @@ class SourceManager
           File.chmod 0600, fn
           FileUtils.mv fn, bakfn, :force => true unless File.exists?(bakfn) && File.size(fn) == 0
         end
-        Redwood::save_yaml_obj sources.sort_by { |s| s.id.to_i }, fn, true
+        Redwood::save_yaml_obj sources, fn, true
         File.chmod 0600, fn
       end
       @sources_dirty = false
index 5776d7e384d1749e6e6af8c5cd9ed7e10d985763..adf44b7ccbd2b46f056a47fdf04dfa9a650275c5 100644 (file)
@@ -91,7 +91,7 @@ end
 
 class Range
   ## only valid for integer ranges (unless I guess it's exclusive)
-  def size 
+  def size
     last - first + (exclude_end? ? 0 : 1)
   end
 end