rename builds -> bots

This commit is contained in:
Lunny Xiao authored and Jason Song committed 2022-11-25 17:48:48 +08:00
1 parent c61ac24c1c
commit 2ecb59c092
24 files changed
+81 -78

No files matched your search

+2 -2
View File
@@ -45,12 +45,12 @@ func NewNotifier() base.Notifier {
}
func notify(repo *repo_model.Repository, doer *user_model.User, ref string, evt webhook.HookEventType, payload api.Payloader) error {
if unit.TypeBuilds.UnitGlobalDisabled() {
if unit.TypeBots.UnitGlobalDisabled() {
return nil
}
if err := repo.LoadUnits(db.DefaultContext); err != nil {
return fmt.Errorf("repo.LoadUnits: %w", err)
} else if !repo.UnitEnabled(unit.TypeBuilds) {
} else if !repo.UnitEnabled(unit.TypeBots) {
return nil
}