[smuxi] [Engine] Fixed GitMessageBuffer.Count



commit 37c8fcfcf5f9628e5aec03d70982780abcc7faa6
Author: Mirco Bauer <meebey meebey net>
Date:   Sun Feb 26 11:54:23 2012 +0100

    [Engine] Fixed GitMessageBuffer.Count

 src/Engine/MessageBuffers/GitMessageBuffer.cs |   13 +------------
 1 files changed, 1 insertions(+), 12 deletions(-)
---
diff --git a/src/Engine/MessageBuffers/GitMessageBuffer.cs b/src/Engine/MessageBuffers/GitMessageBuffer.cs
index d72364c..82c0cef 100644
--- a/src/Engine/MessageBuffers/GitMessageBuffer.cs
+++ b/src/Engine/MessageBuffers/GitMessageBuffer.cs
@@ -128,18 +128,7 @@ namespace Smuxi.Engine
         #region implemented abstract members of Smuxi.Engine.MessageBufferBase
         public override int Count {
             get {
-                var repo = Repository;
-                var count = repo.Index.Count;
-                var reference = repo.Refs["refs/heads/master"] as DirectReference;
-                if (reference == null) {
-                    return count;
-                }
-                var commit = reference.Target as Commit;
-                if (commit == null) {
-                    return count;
-                }
-                count += commit.Tree.Count;
-                return count;
+                return Repository.Index.Count;
             }
         }
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]