1
0
mirror of https://git.tt-rss.org/git/tt-rss.git synced 2025-12-21 05:11:29 +00:00

get_article_image: return basic kind to which flavor image belongs

This commit is contained in:
Andrew Dolgov
2020-12-07 12:09:06 +03:00
parent db3fcb861b
commit e40b79ab33
2 changed files with 13 additions and 2 deletions

View File

@@ -786,11 +786,15 @@ class API extends Handler {
$headline_row["content"] = DiskCache::rewriteUrls($headline_row['content']);
list ($flavor_image, $flavor_stream) = Article::get_article_image($enclosures, $line["content"], $line["site_url"]);
list ($flavor_image, $flavor_stream, $flavor_kind) = Article::get_article_image($enclosures, $line["content"], $line["site_url"]);
$headline_row["flavor_image"] = $flavor_image;
$headline_row["flavor_stream"] = $flavor_stream;
/* optional */
if ($flavor_kind)
$headline_row["flavor_kind"] = $flavor_kind;
array_push($headlines, $headline_row);
}
} else if (is_numeric($result) && $result == -1) {