added catch for TypeError

when value is not required and save empty string, form clean make it None value. But None value bad for strptime method of datetime