diff --git a/sessionmanager/sessiondelegate.go b/sessionmanager/sessiondelegate.go index c89794771..88fba98d2 100644 --- a/sessionmanager/sessiondelegate.go +++ b/sessionmanager/sessiondelegate.go @@ -72,9 +72,7 @@ func (rsd *SessionDelegate) OnChannelAnswer(ev Event, s *Session) { } func (rsd *SessionDelegate) OnChannelHangupComplete(ev Event, s *Session) { - log.Print(s) - log.Print(s.CallCosts) - if len(s.CallCosts) == 0 { + if s != nil && len(s.CallCosts) == 0 { return // why would we have 0 callcosts } lastCC := s.CallCosts[len(s.CallCosts)-1]