Skip to content

Commit 19d9c94

Browse files
committed
some improvements
1 parent 94d8868 commit 19d9c94

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

services/pull/check.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -404,11 +404,12 @@ func CheckPRsForBaseBranch(ctx context.Context, baseRepo *repo_model.Repository,
404404
// Init runs the task queue to test all the checking status pull requests
405405
func Init() error {
406406
prPatchCheckerQueue = queue.CreateUniqueQueue(graceful.GetManager().ShutdownContext(), "pr_patch_checker", handler)
407-
408407
if prPatchCheckerQueue == nil {
409408
return fmt.Errorf("unable to create pr_patch_checker queue")
410409
}
411410

411+
notify_service.RegisterNotifier(newNotifier())
412+
412413
go graceful.GetManager().RunWithCancel(prPatchCheckerQueue)
413414
go graceful.GetManager().RunWithShutdownContext(InitializePullRequests)
414415
return nil

services/pull/notify.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@ type pullNotifier struct {
1818

1919
var _ notify_service.Notifier = &pullNotifier{}
2020

21-
// NewNotifier create a new indexerNotifier notifier
22-
func NewNotifier() notify_service.Notifier {
21+
// newNotifier create a new indexerNotifier notifier
22+
func newNotifier() notify_service.Notifier {
2323
return &pullNotifier{}
2424
}
2525

0 commit comments

Comments
 (0)