wasn't comparing times correctly