fixed date comparison bug in command line mode