Fix for safari date validation