Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitb7e88f0

Browse files
committed
fix: remove closed check when starting notification manager
1 parentcba69f3 commitb7e88f0

File tree

1 file changed

+0
-11
lines changed

1 file changed

+0
-11
lines changed

‎coderd/notifications/manager.go

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,6 @@ type Manager struct {
5353
success,failurechandispatchResult
5454

5555
mu sync.Mutex// Protects following.
56-
closedbool
5756
notifier*notifier
5857

5958
runOnce sync.Once
@@ -161,11 +160,6 @@ func (m *Manager) loop(ctx context.Context) error {
161160
}()
162161

163162
m.mu.Lock()
164-
ifm.closed {
165-
m.mu.Unlock()
166-
returnxerrors.New("manager already closed")
167-
}
168-
169163
vareg errgroup.Group
170164

171165
m.notifier=newNotifier(ctx,m.cfg,uuid.New(),m.log,m.store,m.handlers,m.helpers,m.metrics,m.clock)
@@ -354,11 +348,6 @@ func (m *Manager) Stop(ctx context.Context) error {
354348
m.mu.Lock()
355349
deferm.mu.Unlock()
356350

357-
ifm.closed {
358-
returnnil
359-
}
360-
m.closed=true
361-
362351
m.log.Debug(context.Background(),"graceful stop requested")
363352

364353
// If the notifier hasn't been started, we don't need to wait for anything.

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp