

def _filter_by_date(journal, after, before):
    'return a list of entries after date\n\n    :param before: A naive datetime representing a UTC time.\n    :param after: A naive datetime representing a UTC time\n    '
    if ((after is None) and (before is None)):
        return journal
    return [item for item in journal if (((after is None) or (item['Creation Date'] >= after)) and ((before is None) or (item['Creation Date'] < before)))]

dataset/ETHPy150Open nathangrigg/dayone_export/dayone_export/__init__.py _filter_by_date/original