mirror of
https://git.tt-rss.org/fox/tt-rss.git
synced 2025-08-05 21:57:24 +02:00
Use existing headline info for 'Article.displayUrl()'
This commit is contained in:
parent
da4b886f08
commit
5b99ccf662
@ -123,15 +123,12 @@ const Article = {
|
||||
Article.setActive(0);
|
||||
},
|
||||
displayUrl: function (id) {
|
||||
const query = {op: "Article", method: "getmetadatabyid", id: id};
|
||||
const hl = Headlines.objectById(id);
|
||||
|
||||
xhr.json("backend.php", query, (reply) => {
|
||||
if (reply && reply.link) {
|
||||
prompt(__("Article URL:"), reply.link);
|
||||
} else {
|
||||
alert(__("No URL could be displayed for this article."));
|
||||
}
|
||||
});
|
||||
if (hl?.link)
|
||||
prompt(__("Article URL:"), hl.link);
|
||||
else
|
||||
alert(__("No URL could be displayed for this article."));
|
||||
},
|
||||
openInNewWindow: function (id) {
|
||||
/* global __csrf_token */
|
||||
|
Loading…
Reference in New Issue
Block a user