forked from forgejo/forgejo
Add repo info to web hook post
This commit is contained in:
parent
495d939ca5
commit
23a857d107
4 changed files with 39 additions and 4 deletions
|
@ -88,6 +88,11 @@ type Repository struct {
|
|||
Updated time.Time `xorm:"updated"`
|
||||
}
|
||||
|
||||
func (repo *Repository) GetOwner() (err error) {
|
||||
repo.Owner, err = GetUserById(repo.OwnerId)
|
||||
return err
|
||||
}
|
||||
|
||||
// IsRepositoryExist returns true if the repository with given name under user has already existed.
|
||||
func IsRepositoryExist(user *User, repoName string) (bool, error) {
|
||||
repo := Repository{OwnerId: user.Id}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue