Skip to content

Commit

Permalink
feat: handle channel hangup request
Browse files Browse the repository at this point in the history
This happens when the far end is ringing but has not accepted the
call and instead declines it. In such cases the originating channel will
be terminated as well.
  • Loading branch information
crazybolillo committed Sep 28, 2024
1 parent 8ba1977 commit c16a058
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions internal/serve/serve.go
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,8 @@ func serve(ctx context.Context, conn *websocket.Conn, debug bool) int {
switch evt.Type {
case "StasisStart":
handleStart(payload)
case "ChannelHangupRequest":
fallthrough
case "StasisEnd":
handleEnd(payload)
default:
Expand Down

0 comments on commit c16a058

Please sign in to comment.