Merge pull request #1255 from thelounge/xPaw/og-description

Check og:description before description
This commit is contained in:
Jérémie Astori 2017-06-26 01:44:54 -04:00 committed by GitHub
commit 0239fdd2fb

View File

@ -55,8 +55,8 @@ function parse(msg, url, res, client) {
toggle.type = "link"; toggle.type = "link";
toggle.head = $("title").text(); toggle.head = $("title").text();
toggle.body = toggle.body =
$("meta[name=description]").attr("content") $("meta[property=\"og:description\"]").attr("content")
|| $("meta[property=\"og:description\"]").attr("content") || $("meta[name=\"description\"]").attr("content")
|| "No description found."; || "No description found.";
toggle.thumb = toggle.thumb =
$("meta[property=\"og:image\"]").attr("content") $("meta[property=\"og:image\"]").attr("content")