fixed bug where end dates could be selected