Skip to content

Commit

Permalink
show user who created the repository instead of the organization in a…
Browse files Browse the repository at this point in the history
…ction feed (#5948) (#5956)
  • Loading branch information
adelowo authored and lafriks committed Feb 4, 2019
1 parent 477b4de commit 1a8ab63
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions models/repo.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@ import (
"github.com/Unknwon/com"
"github.com/go-xorm/builder"
"github.com/go-xorm/xorm"
"github.com/mcuadros/go-version"
"gopkg.in/ini.v1"
version "github.com/mcuadros/go-version"
ini "gopkg.in/ini.v1"
)

var repoWorkingPool = sync.NewExclusivePool()
Expand Down Expand Up @@ -1346,14 +1346,14 @@ func createRepository(e *xorm.Session, doer, u *User, repo *Repository) (err err

if err = watchRepo(e, doer.ID, repo.ID, true); err != nil {
return fmt.Errorf("watchRepo: %v", err)
} else if err = newRepoAction(e, u, repo); err != nil {
} else if err = newRepoAction(e, doer, repo); err != nil {
return fmt.Errorf("newRepoAction: %v", err)
}

return nil
}

// CreateRepository creates a repository for the user/organization u.
// CreateRepository creates a repository for the user/organization.
func CreateRepository(doer, u *User, opts CreateRepoOptions) (_ *Repository, err error) {
if !doer.IsAdmin && !u.CanCreateRepo() {
return nil, ErrReachLimitOfRepo{u.MaxRepoCreation}
Expand Down

0 comments on commit 1a8ab63

Please sign in to comment.