[FIX] So it turns out that not just lib/scm but also Ohloh is broken if the commit...
authorRobin Luckey <robin@Tangier.local>
Tue, 20 Jan 2009 17:12:20 +0000 (09:12 -0800)
committerRobin Luckey <robin@Tangier.local>
Tue, 20 Jan 2009 17:13:16 +0000 (09:13 -0800)
      Fine. I give up. I initialize commit.diffs to be [].

lib/scm/parsers/svn_xml_parser.rb

index f8b17839878d1bacb99e844766bd3c15cb3bebd0..2ecab6a2853cbc2333092dfe602f2a18e19ae452 100644 (file)
@@ -17,6 +17,7 @@ module Scm::Parsers
                        case name
                        when 'logentry'
                                @commit = Scm::Commit.new
+                               @commit.diffs = []
                                @commit.token = attrs['revision'].to_i
                        when 'path'
                                @diff = Scm::Diff.new(:action => attrs['action'])
@@ -33,7 +34,6 @@ module Scm::Parsers
                                @commit.committer_date = Time.utc(*ParseDate.parsedate(@text))
                        when 'path'
                                @diff.path = @text
-                               @commit.diffs ||= []
                                @commit.diffs << @diff
                        when 'msg'
                                @commit.message = @text