fixed dates bug