'Optional date-time string'

def opt_datetime(self, line):

    if line.startswith('"'):
        try:
            (spam, date, rest) = line.split('"', 2)
        except IndexError:
            raise IllegalClientResponse('Malformed    date-time')
        return (date, rest[1:])
    else:
        return (None, line)
