def sort_feed_items(items, order):
    """Return feed items, sorted according to sortFeedItems."""
    if order == 'asInFeed':
        return items
    (key, reverse) = _sort_arguments(order)
    try:
        sitems = sorted(items, key=key, reverse=reverse)
    except __HOLE__:
        # feedparser normalizes required timestamp fields in ATOM and RSS
        # to the "published"/"updated" fields. Feeds missing it are unsortable by date.
        return items
    return sitems
dataset/ETHPy150Open ProgVal/Limnoria/plugins/RSS/plugin.py/sort_feed_items