Check channel close before closing