public function getFeedContents($rss, $items = 10, $order = '') : array
    {
        $entries = array();

        if (! empty($rss)) {
            $rss = fetch_feed($rss);
        } else {
            $entries['error'] = __('RSS feed URL is missing', 'modularity');
            return $entries;
        }

        if (is_wp_error($rss)) {
            if (is_admin() || current_user_can('manage_options')) {
                $entries['error'] = __('RSS Error:', 'modularity') . ' ' . $rss->get_error_message();
            }
            return $entries;
        }

        if (!$rss->get_item_quantity()) {
            $entries['error'] = __( 'An error has occurred, which probably means the feed is down. Try again later.', 'modularity');
            $rss->__destruct();
            unset($rss);
            return $entries;
        }

        $items = ($items <= 0) ? 0 : (int) $items;
        $entries = $rss->get_items(0, $items);
        if ($order == 'asc') {
            $entries = array_reverse($entries);
        }

        $rss->__destruct();
        unset($rss);
        return $entries;
    }