Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: prevent panic on closed channel when not stopped
Browse files Browse the repository at this point in the history
Ja7ad committed Jan 13, 2025
1 parent 0b9353e commit 05441bd
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion state/state.go
Original file line number Diff line number Diff line change
@@ -752,5 +752,8 @@ func (st *state) publishEvent(msg any) {
return
}

st.eventCh <- msg
select {
case st.eventCh <- msg:
default:
}
}

0 comments on commit 05441bd

Please sign in to comment.