fix lights code issue