mirror of
https://github.com/discourse/discourse.git
synced 2025-05-22 06:14:12 +08:00
FIX: Get only the correct collapse title in emails (#10228)
Previously, this would get every details block title from the entire post, for every details block.
This commit is contained in:
@ -33,7 +33,7 @@ after_initialize do
|
||||
|
||||
on(:reduce_cooked) do |fragment, post|
|
||||
fragment.css("details").each do |el|
|
||||
text = fragment.css("summary").text
|
||||
text = el.css("summary").text
|
||||
link = fragment.document.create_element("a")
|
||||
link["href"] = post.url if post
|
||||
link.content = I18n.t("details.excerpt_details")
|
||||
|
Reference in New Issue
Block a user