Merge commit '121443c0fca383268b8022c048dd137994785aff' into glitch-soc/main

Conflicts:
- `.rubocop_todo.yml`:
  Upstream regenerated this file, glitch-soc had a specific ignore.
This commit is contained in:
Claire
2023-08-13 18:47:15 +02:00
194 changed files with 3931 additions and 2110 deletions

View File

@ -113,6 +113,7 @@ class LinkDetailsExtractor
title: title || '',
description: description || '',
image_remote_url: image,
image_description: image_alt || '',
type: type,
link_type: link_type,
width: width || 0,
@ -168,6 +169,10 @@ class LinkDetailsExtractor
valid_url_or_nil(opengraph_tag('og:image'))
end
def image_alt
opengraph_tag('og:image:alt')
end
def canonical_url
valid_url_or_nil(link_tag('canonical') || opengraph_tag('og:url'), same_origin_only: true) || @original_url.to_s
end