mirror of
https://git.tt-rss.org/git/tt-rss.git
synced 2025-12-13 20:35:55 +00:00
Revert "api: get flavor image from plugin-processed content"
This reverts commit a4604e892c.
This commit is contained in:
@@ -778,15 +778,13 @@ class API extends Handler {
|
|||||||
|
|
||||||
$hook_object = ["headline" => &$headline_row];
|
$hook_object = ["headline" => &$headline_row];
|
||||||
|
|
||||||
if ($show_content) {
|
|
||||||
PluginHost::getInstance()->chain_hooks_callback(PluginHost::HOOK_RENDER_ARTICLE_API,
|
PluginHost::getInstance()->chain_hooks_callback(PluginHost::HOOK_RENDER_ARTICLE_API,
|
||||||
function ($result) use (&$headline_row) {
|
function ($result) use (&$headline_row) {
|
||||||
$headline_row = $result;
|
$headline_row = $result;
|
||||||
},
|
},
|
||||||
$hook_object);
|
$hook_object);
|
||||||
|
|
||||||
list ($flavor_image, $flavor_stream, $flavor_kind) = Article::get_article_image($enclosures,
|
list ($flavor_image, $flavor_stream, $flavor_kind) = Article::get_article_image($enclosures, $line["content"], $line["site_url"]);
|
||||||
$headline_row["content"], $line["site_url"]);
|
|
||||||
|
|
||||||
$headline_row["flavor_image"] = $flavor_image;
|
$headline_row["flavor_image"] = $flavor_image;
|
||||||
$headline_row["flavor_stream"] = $flavor_stream;
|
$headline_row["flavor_stream"] = $flavor_stream;
|
||||||
@@ -794,7 +792,6 @@ class API extends Handler {
|
|||||||
/* optional */
|
/* optional */
|
||||||
if ($flavor_kind)
|
if ($flavor_kind)
|
||||||
$headline_row["flavor_kind"] = $flavor_kind;
|
$headline_row["flavor_kind"] = $flavor_kind;
|
||||||
}
|
|
||||||
|
|
||||||
array_push($headlines, $headline_row);
|
array_push($headlines, $headline_row);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user