forked from kevadesu/forgejo
Fix actions notify bug (#31866)
Try to fix https://github.com/go-gitea/gitea/issues/31757#issuecomment-2295131062 (cherry picked from commit 4f5c96627b4622d64593db2d436b1f3befa5f3c3)
This commit is contained in:
parent
d34d8ec2cf
commit
bdf477f6ef
3 changed files with 18 additions and 13 deletions
|
@ -396,7 +396,7 @@ func (n *actionsNotifier) ForkRepository(ctx context.Context, doer *user_model.U
|
|||
// Add to hook queue for created repo after session commit.
|
||||
if u.IsOrganization() {
|
||||
newNotifyInput(repo, doer, webhook_module.HookEventRepository).
|
||||
WithRef(oldRepo.DefaultBranch).
|
||||
WithRef(git.RefNameFromBranch(oldRepo.DefaultBranch).String()).
|
||||
WithPayload(&api.RepositoryPayload{
|
||||
Action: api.HookRepoCreated,
|
||||
Repository: convert.ToRepo(ctx, repo, access_model.Permission{AccessMode: perm_model.AccessModeOwner}),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue