From bc60052b519b8b991e50b8ccb30f2b76ad125996 Mon Sep 17 00:00:00 2001 From: scott Chacon Date: Fri, 16 Nov 2007 13:24:30 -0800 Subject: updated the docs --- doc/classes/Git/Object.html | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) (limited to 'doc/classes/Git/Object.html') diff --git a/doc/classes/Git/Object.html b/doc/classes/Git/Object.html index cde1e7d..a755c21 100644 --- a/doc/classes/Git/Object.html +++ b/doc/classes/Git/Object.html @@ -94,7 +94,7 @@ represents a git object

Methods

- new   + new  
@@ -126,12 +126,12 @@ Class Git::Object::Tree

Public Class methods

-
- +
+ @@ -141,11 +141,11 @@ if we’re calling this, we don’t know what type it is yet so this is our little factory method

[Source]

-
+ onclick="toggleCode('M000149-source');return false;">[Source]

+
-# File lib/git/object.rb, line 206
-      def new(base, objectish, is_tag = false)
+# File lib/git/object.rb, line 242
+      def new(base, objectish, type = nil, is_tag = false)
         if is_tag
           sha = base.lib.tag_sha(objectish)
           if sha == ''
@@ -153,8 +153,9 @@ this is our little factory method
           end
           return Tag.new(base, sha, objectish)
         else
-          sha = base.lib.revparse(objectish)
-          type = base.lib.object_type(sha) 
+          if !type
+            type = base.lib.object_type(objectish) 
+          end
         end
         
         klass =
@@ -163,7 +164,7 @@ this is our little factory method
           when /commit/: Commit
           when /tree/:   Tree
           end
-        klass::new(base, sha)
+        klass::new(base, objectish)
       end
 
-- cgit