Add missing two sync feed for refs/pull (#32815) (#32822)
Автор
Lunny Xiao

Коммитер
GitHub
5 месяцев назад 
Файлов изменено: 1
+12–0
8eefa1f
services/feed/action.go
+12–0
@@ -417,6 +417,12 @@ | ||
} | ||
func (a *actionNotifier) SyncCreateRef(ctx context.Context, doer *user_model.User, repo *repo_model.Repository, refFullName git.RefName, refID string) { | ||
// ignore pull sync message for pull requests refs | ||
// TODO: it's better to have a UI to let users chose | ||
if refFullName.IsPull() { | ||
return | ||
} | ||
if err := activities_model.NotifyWatchers(ctx, &activities_model.Action{ | ||
ActUserID: repo.OwnerID, | ||
ActUser: repo.MustOwner(ctx), | ||
@@ -431,6 +437,12 @@ | ||
} | ||
func (a *actionNotifier) SyncDeleteRef(ctx context.Context, doer *user_model.User, repo *repo_model.Repository, refFullName git.RefName) { | ||
// ignore pull sync message for pull requests refs | ||
// TODO: it's better to have a UI to let users chose | ||
if refFullName.IsPull() { | ||
return | ||
} | ||
if err := activities_model.NotifyWatchers(ctx, &activities_model.Action{ | ||
ActUserID: repo.OwnerID, | ||
ActUser: repo.MustOwner(ctx), |
GPG верификация
Статус: Неверифицирован
Причина: Не найден публичный ключ
ID ключа: b5690eeebb952194
Cherry-pick
Команда cherry-pick позволяет выбрать отдельные коммиты из одной ветки и применить их к другой.