Fixed light shutdown issue