optimizing date picker