diff options
author | slene <vslene@gmail.com> | 2014-03-28 19:34:01 +0800 |
---|---|---|
committer | slene <vslene@gmail.com> | 2014-03-28 19:34:01 +0800 |
commit | d800a44a26216747b1a60a21090c581dfbe23ff4 (patch) | |
tree | c92d3a82d5eada3e1815b81453f952bc29fa76aa /models/git.go | |
parent | 04bc86cafc17403194a10d8b066aa51521bff447 (diff) | |
download | gitea-d800a44a26216747b1a60a21090c581dfbe23ff4.tar.gz gitea-d800a44a26216747b1a60a21090c581dfbe23ff4.zip |
display commits by sha1 id
Diffstat (limited to 'models/git.go')
-rw-r--r-- | models/git.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/models/git.go b/models/git.go index e2ee52083d..34f0267f65 100644 --- a/models/git.go +++ b/models/git.go @@ -244,11 +244,11 @@ func GetCommitsByCommitId(userName, repoName, commitId string) (*list.List, erro if err != nil { return nil, err } - r, err := repo.LookupReference(commitId) + oid, err := git.NewOidFromString(commitId) if err != nil { return nil, err } - return r.AllCommits() + return repo.CommitsBefore(oid) } // Diff line types. |