|
@@ -48,14 +48,7 @@ func Search(c *context.APIContext) {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- tmprepos, count, err := models.SearchRepositoryByName(opts)
|
|
|
- var repos []*models.Repository
|
|
|
-
|
|
|
- for _, repo := range tmprepos {
|
|
|
- if !repo.IsPrivate {
|
|
|
- repos = append(repos, repo)
|
|
|
- }
|
|
|
- }
|
|
|
+ repos, count, err := models.SearchRepositoryByName(opts)
|
|
|
if err != nil {
|
|
|
c.JSON(500, map[string]interface{}{
|
|
|
"ok": false,
|