make end time optional