added daytimechecker code