diff --git a/dao/accesslog.go b/dao/accesslog.go index 930607701..2aa1d46e7 100644 --- a/dao/accesslog.go +++ b/dao/accesslog.go @@ -184,7 +184,7 @@ func GetTopRepos(countNum int) ([]models.TopRepo, error) { for i := 0; i < len(list); i++ { for _, v := range usrnameList { if v.RepoName == list[i].RepoName { - list[i].Creator = v.Creator + // list[i].Creator = v.Creator break } } diff --git a/dao/dao_test.go b/dao/dao_test.go index 3d375927d..49de1d1a6 100644 --- a/dao/dao_test.go +++ b/dao/dao_test.go @@ -770,9 +770,11 @@ func TestGetTopRepos(t *testing.T) { if topRepos[0].AccessCount != 1 { t.Errorf("error occured in get top reop's access count, expected: %v, actual: %v", 1, topRepos[0].AccessCount) } - if topRepos[0].Creator != currentUser.Username { - t.Errorf("error occured in get top reop's creator, expected: %v, actual: %v", currentUser.Username, topRepos[0].Creator) - } + /* + if topRepos[0].Creator != currentUser.Username { + t.Errorf("error occured in get top reop's creator, expected: %v, actual: %v", currentUser.Username, topRepos[0].Creator) + } + */ err = ToggleProjectPublicity(currentProject.ProjectID, publicityOff) if err != nil { t.Errorf("Error occurred in ToggleProjectPublicity: %v", err) diff --git a/models/toprepo.go b/models/toprepo.go index 6ccb46227..b977e4c18 100644 --- a/models/toprepo.go +++ b/models/toprepo.go @@ -19,5 +19,5 @@ package models type TopRepo struct { RepoName string `json:"name"` AccessCount int64 `json:"count"` - Creator string `json:"creator"` + // Creator string `json:"creator"` } diff --git a/static/resources/js/components/top-repository/top-repository.directive.html b/static/resources/js/components/top-repository/top-repository.directive.html index c45a7adfa..a44c1dc93 100644 --- a/static/resources/js/components/top-repository/top-repository.directive.html +++ b/static/resources/js/components/top-repository/top-repository.directive.html @@ -18,8 +18,7 @@
// 'repository_name' | tr // | -// 'count' | tr // | -// 'creator' | tr // | +// 'count' | tr // |
---|