Fix str2datetime