Skip to content

Commit

Permalink
fix: args for cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
Sattar Salambayev committed Jul 1, 2020
1 parent 0220540 commit db19975
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions server.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ func (srv *server) Start() error {
//}

<-srv.close
srv.cleanup(srv.unbindQsAtStop, srv.unbindExAtStop)
srv.cleanup()

return nil
}
Expand Down Expand Up @@ -310,15 +310,15 @@ func (srv *server) Endpoint(endpoint string, handler Handler) error {
return nil
}

func (srv *server) cleanup(unbindQs, unbindEx bool) error {
if unbindQs {
func (srv *server) cleanup() error {
if srv.unbindQsAtStop {
srv.sess.log.Info("started cleanup server rec channels")
if err := srv.cleanupRec(); err != nil {
return err
}
}

if unbindEx {
if srv.unbindExAtStop {
srv.sess.log.Info("started cleanup server sen channels")
if err := srv.cleanupSen(); err != nil {
return err
Expand Down

0 comments on commit db19975

Please sign in to comment.