only check no fork logic if pull request
This commit is contained in:
parent
616433b709
commit
c36bf0d5ee
1 changed files with 9 additions and 7 deletions
|
@ -78,7 +78,8 @@ func (t *triggerer) Trigger(ctx context.Context, repo *core.Repository, base *co
|
||||||
logger.Infoln("trigger: skipping hook. found skip directive")
|
logger.Infoln("trigger: skipping hook. found skip directive")
|
||||||
return nil, nil
|
return nil, nil
|
||||||
}
|
}
|
||||||
if repo.IgnorePulls && base.Event == core.EventPullRequest {
|
if base.Event == core.EventPullRequest {
|
||||||
|
if repo.IgnorePulls {
|
||||||
logger.Infoln("trigger: skipping hook. project ignores pull requests")
|
logger.Infoln("trigger: skipping hook. project ignores pull requests")
|
||||||
return nil, nil
|
return nil, nil
|
||||||
}
|
}
|
||||||
|
@ -86,6 +87,7 @@ func (t *triggerer) Trigger(ctx context.Context, repo *core.Repository, base *co
|
||||||
logger.Infoln("trigger: skipping hook. project ignores forks")
|
logger.Infoln("trigger: skipping hook. project ignores forks")
|
||||||
return nil, nil
|
return nil, nil
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
user, err := t.users.Find(ctx, repo.UserID)
|
user, err := t.users.Find(ctx, repo.UserID)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
Loading…
Reference in a new issue