Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
project
drupal
Commits
b7a6096b
Commit
b7a6096b
authored
Feb 15, 2014
by
alexpott
Browse files
Issue
#2195779
by ParisLiakos: Remove aggregator_load_feed_items().
parent
fcb52a6a
Changes
1
Show whitespace changes
Inline
Side-by-side
core/modules/aggregator/aggregator.pages.inc
deleted
100644 → 0
View file @
fcb52a6a
<?php
/**
* @file
* User page callbacks for the Aggregator module.
*/
/**
* Loads and optionally filters feed items.
*
* @param string $type
* The type of filter for the items. Possible values are:
* - sum: No filtering.
* - source: Filter the feed items, limiting the result to items from a
* single source.
* @param mixed $data
* Feed data used for filtering. The type and value of $data depends on $type:
* - source: $data is an object with $data->fid identifying the feed used to
* as filter.
* The $data parameter is not used when $type is 'sum'.
* @param int $limit
* (optional) The number of records to return. Defaults to 20.
*
* @deprecated Use \Drupal\aggregator\ItemStorageController::loadAll() for
* loading all feed items, \Drupal\aggregator\ItemStorageController::loadByFeed()
*
* @return \Drupal\aggregator\ItemInterface[]
* An array of the feed items.
*/
function
aggregator_load_feed_items
(
$type
,
$data
=
NULL
,
$limit
=
20
)
{
$storage_controller
=
\
Drupal
::
entityManager
()
->
getStorageController
(
'aggregator_item'
);
switch
(
$type
)
{
case
'sum'
:
return
$storage_controller
->
loadAll
(
$limit
);
case
'source'
:
return
$storage_controller
->
loadByFeed
(
$data
->
id
(),
$limit
);
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment